I am deeply interested in analyzing disparities in incarceration rates by race due to personal experiences and discussions with my brother, who holds a Ph.D. in sociology and is a professor of criminal justice. His insights and discussions about this topic throughout my life have sparked my curiosity about this potential racially-based issue. Additionally, the question raised in a Racial Issues IQ Quiz about the differences in prison time for African Americans compared to whites convicted of the same crimes further motivated me to delve into this analysis.
- Python
- Microsoft Excel
- Microsoft Powerpoint
- Windows 11
The pandas and matplotlib libraries are imported to perform the data analysis (sorting of the data) and visualization(creation of statistical Charts). The FuncFormatter Class is used to create tick labels on the visualization graphs.
The data is read in from the .csv file which contains the population of sentenced prisoners by race separated in columns from 2011-2021. Percents are taken from these columns and used to create a data frame which is then used to create a pivot table
The pivot table is then set to a bar graph and the specific changes to the graph are recorded here as well.
The same was done in the second program for the second data chart visualization. However, the columns of data are Black, White, and Hispanic representing the different race populations charged with drug possession from 2014-2019