(self, first_attr, second_attr)
return dictify_df(tmp_df)
Returns a dictionary {first_val -> {second_val -> count } } where:
            <first_val>: all possible values for first_attr
            <second_val>: all values for second_attr that appear at least once with <first_val>
            <count>: frequency (# of entities) where first_attr=<first_val> AND second_attr=<second_val>
        Filters out NULL values so no entries in the dictionary would have NULLs.
Returns a dictionary {first_val -> {second_val -> count } } where:
            <first_val>: all possible values for first_attr
            <second_val>: all values for second_attr that appear at least once with <first_val>
            <count>: frequency (# of entities) where first_attr=<first_val> AND second_attr=<second_val>
        Filters out NULL values so no entries in the dictionary would have NULLs.
Returns a dictionary { first_val - > { second_val - > count } } where : <first_val > : all possible values for first_attr <second_val > : all values for second_attr that appear at least once with <first_val > <count > : frequency ( # of entities ) where first_attr = <first_val > AND second_attr = <second_val > Filters out NULL values so no entries in the dictionary would have NULLs .
def get_stats_pair(self, first_attr, second_attr):
        """
        Returns a dictionary {first_val -> {second_val -> count } } where:
            <first_val>: all possible values for first_attr
            <second_val>: all values for second_attr that appear at least once with <first_val>
            <count>: frequency (# of entities) where first_attr=<first_val> AND second_attr=<second_val>
        Filters out NULL values so no entries in the dictionary would have NULLs.
        """
        data_df = self.get_raw_data()
        tmp_df = data_df[[first_attr, second_attr]]\
            .loc[(data_df[first_attr] != NULL_REPR) & (data_df[second_attr] != NULL_REPR)]\
            .groupby([first_attr, second_attr])\
            .size()\
            .reset_index(name="count")
        return dictify_df(tmp_df)
def get_stats_pair ( self , first_attr , second_attr ) : data_df = self . get_raw_data ( ) tmp_df = data_df [ [ first_attr , second_attr ] ] . loc [ ( data_df [ first_attr ] != NULL_REPR ) & ( data_df [ second_attr ] != NULL_REPR ) ] . groupby ( [ first_attr , second_attr ] ) . size ( ) . reset_index ( name = "count" ) return dictify_df ( tmp_df )