diff --git a/crm_rfm_modeling/rfm.py b/crm_rfm_modeling/rfm.py index 2e7b962..fd80d54 100644 --- a/crm_rfm_modeling/rfm.py +++ b/crm_rfm_modeling/rfm.py @@ -107,7 +107,7 @@ def fit(self,data,dataset_type='customer',scoring_method="quintile",recency_end_ raise ValueError('Error: expected 3 columns for dataset type of '+ self.dataset_type +'; received: ' + str(data.shape[1])) if self.dataset_type == 'transactional': - self.data = convert_transaction_to_user(self.data, recency_end_date=recency_end_date) + self.data = convert_transaction_to_user(self.data, recency_end_date=self.recency_end_date) #### Scoring Section #Retrieving the indexes for each R-F-M categorized within each dictionary for each score @@ -169,4 +169,4 @@ def __str__(self): s = "Parameters:\n\tDataset_Type: "+str(self.dataset_type)+"\n\tScoring_Method: "+str(self.scoring_method)+"\n\tWeights: "+str(self.weights)+"\n" output = s + print_kwargs(self.__dict__) return output - \ No newline at end of file +