Skip to content

joe-c-29b/Python_Functions

Repository files navigation

Python_Functions

cohort_date2term_converter - a function for converting the begin and end dates of a member of any cohort into academic terms. input: a "cohort.csv" file containing a dataframe with beginning and ending dates and the current academic term as a 5 digit integer. output: a new dataframe where the beginning date and end date have been converted to a start term and an end term.

Pivot_Custom_Table - Function for creating pivot tables when using 2 to 8 demographic combinations. input: a .csv file containing the dataframe that you wish to convert to a pivot table AND the # of columns that are going to be involved in the pivot. output: a pivot table matching the input needs.

CourseSurveySummaryStatistics - Function for calculating some descriptive summary statistics for each individual course during the semester to accompany the end of term student survey results. input: 1 dataframe with information for each course offered for the current term, 1 dataframe with information for the students that were enrolled during the current semester, 1 dataframe to serve as a key between the summarized student data and the summarized course data. output: a dataframe showing descriptive summary statistics for each course.

Date2TermConverter - Function for converting time/date values to academic terms. input: 1 dataframe, the string value of the name of the column with the date/time values you are converting, the string value of the name of the new column you want created to house the academic term. output: a new dataframe with a column that has the appropriate academic term.

Quick_pdfMerger - A quick function to further simplify us of pypdf PdfMerger function so that I don't need to have an adobe subscription or use a sketchy website. input: a list of pdf files that you want merged together. output: a single pdf file containing all of the pages from the input list.

Convert2List_4SQLuse - A quick and easy function for converting long lists of strings in excel into lists for use in SQL WHERE clause. input: a string value that is the name of the .csv that contains the list of strings that you want converted. output: a list that can be copied and pasted into an SQL WHERE ________ IN () clause.

MessyApptSystem_Cleaner - a Python function that takes a messy .csv created by copying and pasting out of a an online scheduling system that does not offer a downloading option for the data; returns a cleaned dataframe with proper columns and rows. input: a very messy .csv without proper columns or rows output: a clean dataframe with proper columns and rows

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published