Homework 4: due by beginning of class as noted in Canvas as a Jupyter notebook. Try to obey the rules for clean, concise code and comment your assignments where you think appropriate. “Some assembly...

1 answer below »
There are 3 coding question. Only choose 2 that are suitable for you. The code must be on jupyter notebook with good comments please


Homework 4: due by beginning of class as noted in Canvas as a Jupyter notebook. Try to obey the rules for clean, concise code and comment your assignments where you think appropriate. “Some assembly required:” any sources used should be cited, and feel free to ask lots of questions. Total: 50 points, 25 for each section you choose. ​You may choose to write code for any two of the following three prompts! Coding 1: Concepts of Computer Programming and the Fantastic Beasts (12.5 points each for parent and child implementation) You are a mad computer scientist and have made an entirely new Python animal! Write one new Python class for a new fantastical or mythical creature that has ​two methods and three attributes.​ These methods and attributes may be of any kind and say or do whatever you want. At least one method should change an attribute of the animal when invoked. At least one method should take user-submitted input! Radical or obscure mythical animals will receive shout-outs. Make a child beast that inherits from the parent beast. The child must ​override at least one method from the parent​. It must also ​inherit at least one of the parent’s attributes. Coding 2: Python Pandas: Thankfully Not Endangered (5 points for part 1, 10 for parts 2 and 3) Using Pandas and tabular data of your choice (it can be junk data or real data in a CSV, Excel, or whatever): 1. Import the data into a dataframe, ensuring the dataframe has good column names and a descriptive, useful index (​not just auto-numbered rows!​). 2. Show that the data imported is ​clean​ - each row has valid values in the context of each column, by writing some Python code that analyzes it. For example, your code might show you have no blank cells and no cells with data that does not fit the desired format of the data. If the data isn’t clean, fix any problems you discover via Python code. 3. Perform one operation on the dataframe to query the data, showing some minor but meaningful conclusion like the minimum or maximum of a specific column. Perform a second operation that involves an insight across two columns. Coding 3: SQLite, SQL, and You (5 points for parts 1, 2, 4, 10 points for part 3) 1. Create a SQLite database named “hw4.db” from your Jupyter notebook. Include a schema with at least six unique columns. 2. Load the database with at least five rows of data using the appropriate SQL commands. 3. Run two SQL statements such that each statement returns a single row of the data from the database. The two statements must use different syntax or operational choices. 4. Return a count of the rows in the database, and then delete a row of the data. Return a count of the remaining rows in the database.
Answered 2 days AfterNov 30, 2021

Answer To: Homework 4: due by beginning of class as noted in Canvas as a Jupyter notebook. Try to obey the...

Suraj answered on Dec 03 2021
130 Votes
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here