ratpmetro/main.py
def _df_processed_loc(self, year=None, loc=None):
        """
        Return self.df_processed within the given year or time period
        """
        assert self.df is not None
        if self.df_processed is None:
            self.process()

        # Focus on a specific year or time period
        if year is not None:
            df = self.df_processed.loc[f"{year}-01-01":f"{year}-12-31"]
        elif loc is not None:
            df = self.df_processed.loc[loc[0] : loc[1]]
        else:
            df = self.df_processed
        return df

        Return self.df_processed within the given year or time period
        
Return self.df_processed within the given year or time period
Return self . df_processed within the given year or time period
def _df_processed_loc(self, year=None, loc=None):
        assert self.df is not None
        if self.df_processed is None:
            self.process()
        if year is not None:
            df = self.df_processed.loc[f"{year}-01-01":f"{year}-12-31"]
        elif loc is not None:
            df = self.df_processed.loc[loc[0] : loc[1]]
        else:
            df = self.df_processed
        return df
def _df_processed_loc ( self , year = None , loc = None ) : assert self . df is not None if self . df_processed is None : self . process ( ) if year is not None : df = self . df_processed . loc [ f"{year}-01-01" : f"{year}-12-31" ] elif loc is not None : df = self . df_processed . loc [ loc [ 0 ] : loc [ 1 ] ] else : df = self . df_processed return df
Return self.df_processed within the given year or time period
Return self . df_processed within the given year or time period
"""
        Return self.df_processed within the given year or time period
        """ # Focus on a specific year or time period
self
year
loc