Skip to content

Helper functions for pandas/sklearn, useful for analysis of behavior

License

Notifications You must be signed in to change notification settings

samtashukla/mlToolbox

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mlToolbox

Python functions for manipulating pandas dataframes, useful for behavioral analyses, general data exploration, and modeling.

Dependencies

  • numpy
  • scipy
  • pandas
  • scikit-learn

pandas_helpers.py

Contains various functions to preprocess pandas dataframes (e.g., transforming features, imputing missing data), as well as functions to fit and evaluate various models using sklearn.

  • fit_evaluate_models: Given samples (X) and a continuous or categorical vector to predict (y), train/test various models using a cross-validation approach, and return a pandas dataframe with evaluative metrics matching the type of dependent variable (e.g., coefficient of determination for a continuous DV, accuracy for a categorical DV). Optionally scale the features (across samples), or add in polynomial + interaction features.

About

Helper functions for pandas/sklearn, useful for analysis of behavior

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages