Pandas-DataFrame-2.1.5

Practice example of using Pandas to create a DataFrame. Word problem is: The hospital where Shen Lee works is going to implement a new database to manage all human resources (HR) information. This includes the personal details of all the staff members across every department as well as annual leave, sick leave, and personal leave. Shen Lee's team will have access to this database for analysis using Python. Therefore, to ensure the data is stored in a way that will enable analysis in the future, Shen Lee is working on the new database configuration. The database tables need to be set up so that the data can be imported into a DataFrame. The following raw data was provided by HR: Staff members and employment units (in brackets): Shen Lee (1), Leon Buhle (0.5), Tracy Adams (0.8), Lebo Sinuka (1.5), Lauren Pierce (1.2), Monika Bond (2), Natahs Allsopp (0.3), Nicholas Winter (1.1), Christopher Eckson (2.2), and Siobhan O’Malley (1.5). Personnel numbers: Shen Lee (215), Leon Buhle (216), Tracy Adams (217), Lebo Sinuka (218), Lauren Pierce (219), Monika Bond (220), Natahs Allsopp (221), Nicholas Winter (222), Christopher Eckson (223), and Siobhan O’Malley (224). Leave per cycle: 10 days sick leave, 20 days annual leave, 5 days personal leave, and 3 days added for one full unit of employment as a bonus. Leave taken in the current cycle (days): Shen Lee: 0 days Leon Buhle: 2 sick, 0 annual leave, 1 personal Tracy Adams: 0 sick, 5 annual leave, 0 personal Lebo Sinuka: 1 sick, 4 annual leave, 5 personal Lauren Pierce: 3 sick, 2 annual leave, 0 personal Monika Bond: 0 sick, 5 annual leave, 3 personal Natahs Allsopp: 1 sick, 10 annual leave, 0 personal Nicholas Winter: 0 sick, 8 annual leave, 1 personal Christopher Eckson: 2 sick, 10 annual leave, 3 personal Siobhan O’Malley: 5 sick, 0 annual leave, 0 personal