ask 1: Please write Python codes to do the following task. (50%)[5pt] Read the data file into Python as a pandas data frame[5pt] Display only the top 5 rows from the dataset. There should be only 5...










ask 1: Please write Python codes to do the following task. (50%)











  1. [5pt] Read the data file into Python as a pandas data frame



  2. [5pt] Display only the top 5 rows from the dataset. There should be only 5 rows.



  3. [5pt] Display only the selected columns (survived, pclass, sex, cabin). There should be only 4 columns.



  4. [5pt] Display only passenger ID and passenger name for survived people. The result should have three columns, ID, name and survived.



  5. [5pt] Create a new dataframe and only save female records. Display the number of records of the new data frame.



  6. [5pt] Save the new data frame from item 5 to a csv file.



  7. [10pt] Print survived people who are older than 50 or in the upper socio-economic status (pclass is 1).



  8. [10pt] I only want to do analysis on survived people. Then, please create one data frame called "dat1" with fare data, and create another data frame called "dat2" with three columns sex, age, pclass.















Task 2: Essay on Problem Definition (40%)











  1. [4pt] Give an analytical question which can be answered by descriptive analysis.



  2. [4pt] Give an analytical question which can be answered by diagnostic analysis.



  3. [4pt] Give an analytical question which can be answered by predictive analysis.



  4. [3pt] Come up with a general business problem.



  5. [10pt] List a few analytical questions which can be solved/answered by individual projects. Please also indicate whether they are descriptive/diagnostic/predictive/prescriptive question.



  6. [10pt] Pick one diagnostic or predictive analytical question from item 4 for this quesiton. If you are allowed to collect any data from the world, what data would you collect to conduct your analysis? Please list the 3 most important datasets you want to collect, and where do these data come from? (e.g. any commercial database? by survey? from business activities?...etc.)



  7. [5pt] Think about the data you mentioned in item 5, will there be any problem/difficult to obtain the data? (e.g. "I want to use SSN for my analysis, but it is sensitive data and I cannot get it", "I want to collect everybody's salary in the US, but there are too many people and I cannot collect it"...)



Jan 31, 2023
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here