strava_map/map.py
def create_heatmap(self):
        """Creates a heatmap of Strava activity data
        Args:
            activities (str or list, optional): A string or list of activities
                to include in the heatmap. Defaults to 'All'.
        """        
                
        heatmap_coordinates = self._coordinates_by_type()
        gradients = self._generate_gradients()
        for a_type, coords in heatmap_coordinates.items():
            feature_group = folium.FeatureGroup(name=a_type, show=True)
            gradient = gradients[a_type]
            feature_group.add_child(HeatMap(coords, radius=7, blur=5, gradient=gradient))
            self.heatmap.add_child(feature_group)
            
        self.heatmap.add_child(folium.map.LayerControl())
                
        filename = "_".join([str(dt.date.today()),
                            self.activity_str,
                            'activities.html'])
        self.heatmap.save(filename)
        webbrowser.open(filename)
Creates a heatmap of Strava activity data
        Args:
            activities (str or list, optional): A string or list of activities
                to include in the heatmap. Defaults to 'All'.
        
Creates a heatmap of Strava activity data
Creates a heatmap of Strava activity data
def create_heatmap(self):
        heatmap_coordinates = self._coordinates_by_type()
        gradients = self._generate_gradients()
        for a_type, coords in heatmap_coordinates.items():
            feature_group = folium.FeatureGroup(name=a_type, show=True)
            gradient = gradients[a_type]
            feature_group.add_child(HeatMap(coords, radius=7, blur=5, gradient=gradient))
            self.heatmap.add_child(feature_group)
        self.heatmap.add_child(folium.map.LayerControl())
        filename = "_".join([str(dt.date.today()),
                            self.activity_str,
                            'activities.html'])
        self.heatmap.save(filename)
        webbrowser.open(filename)
def create_heatmap ( self ) : heatmap_coordinates = self . _coordinates_by_type ( ) gradients = self . _generate_gradients ( ) for a_type , coords in heatmap_coordinates . items ( ) : feature_group = folium . FeatureGroup ( name = a_type , show = True ) gradient = gradients [ a_type ] feature_group . add_child ( HeatMap ( coords , radius = 7 , blur = 5 , gradient = gradient ) ) self . heatmap . add_child ( feature_group ) self . heatmap . add_child ( folium . map . LayerControl ( ) ) filename = "_" . join ( [ str ( dt . date . today ( ) ) , self . activity_str , 'activities.html' ] ) self . heatmap . save ( filename ) webbrowser . open ( filename )
Creates a heatmap of Strava activity data
Creates a heatmap of Strava activity data
"""Creates a heatmap of Strava activity data
        Args:
            activities (str or list, optional): A string or list of activities
                to include in the heatmap. Defaults to 'All'.
        """
self
activities
A string or list of activities
to include in the heatmap. Defaults to 'All'.
A string or list of activities to include in the heatmap . Defaults to ' All ' .