EssayGhost Assignment代写,Essay代写,网课代修,Quiz代考

EssayGhost-Essay代写,作业代写,网课代修代上,cs代写代考

一站式网课代修,论文代写

高质量的Assignment代写、Paper代写、Report代写服务

EG1hao
网课代修代上,cs代写代考
Python代写
您的位置: 主页 > 编程案例 > Python代写 >
代写Python:Meteorite Data Processing代写 assignment代写 data structures代写 - Python代写
发布时间:2021-07-25 21:42:42浏览次数:
Week 7 PA: Meteorite Data ProcessingMeteorite Data Processing代写 For this assignment, you will be working with data from NASA s Open Data Portal about all knownSubmit Assignment Meteorite Data Processing代写Due  Wednesday by 11:59pm Points  10 Submitting  a file upload File Types  pyFor this assignment, you will be working with data from NASA s Open Data Portal about all known meteoritelandings. (Source: Meteorite Landings | NASA Open Data Portal (https://data.nasa.gov/Space  Science/Meteorite Landings/gh4g 9sfh) ).The csv (comma-separated values) file of data you ll be using is Meteorite_Landings.csv . It contains data of all known meteorite landings. I ve slimmed down the data sothere are only a few pieces of data for each meteorite: its name, its mass (rounded to the nearest gram), and its location in (latitude, longitude).Meteorite Data Processing代写The focus of the programming assignment is to practice reading from and writing to files, processing data,and working with data structures (lists and dictionaries). You will use Python to help process information in alarge pool of data, and use string methods to process data stored from files.You have two weeks to complete this assignment. Please do not wait to start the assignment   you have more time to complete this assignment because it will take more time than most programming assignments.Example Meteorite Data Processing代写Below is an example of what the shell should look like when you run your program. Note that the text in black is what the user typed in on their keyboard.Welcome to the Meteorite Landings Database!Enter 1 to look up information on a meteorite by name.Enter 2 to create a new csv file that contains all meteorites greater than a specified mass.Enter 0 to exit.What would you like to do? 1Please enter the name of the meteorite you d like to look up: AachenThe meteorite named Aachen weighed 21 grams and was found at latitude 50.775 and longitude 6.08333Enter 1 to look up information on a meteorite by name.Enter 2 to create a new csv file that contains all meteorites greater than a specified mass.Enter 0 to exit.Meteorite Data Processing代写What would you like to do? 1Please enter the name of the meteorite you d like to look up: Northwest 470ERROR: no meteorite data foundPlease enter the name of the meteorite you d like to look up: Northwest Africa 470The meteorite named Northwest Africa 470 weighed 63 grams and was found at latitude 31.98333 and longitude -4.18667Enter 1 to look up information on a meteorite by name.Enter 2 to create a new csv file that contains all meteorites greater than a specified mass.Enter 0 to exit. Meteorite Data Processing代写What would you like to do? 1Please enter the name of the meteorite you d like to look up: OsterplanaThe meteorite named Osterplana weighed -1 grams and was found at latitude 58.58333 and longitude 13.43333Enter 1 to look up information on a meteorite by name.Enter 2 to create a new csv file that contains all meteorites greater than a specified mass.Enter 0 to exit. Meteorite Data Processing代写What would you like to do? 2Please enter a mass: 15000000File 15000000.csv has been created.Enter 1 to look up information on a meteorite by name.Enter 2 to create a new csv file that contains all meteorites greater than a specified mass.Enter 0 to exit.What would you like to do? 2Please enter a mass: 25000000File 25000000.csv has been created.Enter 1 to look up information on a meteorite by name.Enter 2 to create a new csv file that contains all meteorites greater than a specified mass.Enter 0 to exit.Meteorite Data Processing代写What would you like to do? 0The 15000000.csv file created in this sample run should look like this:ArmantyBacubiritoCampo del CieloCanyon DiabloCape YorkChupaderosGibeonHobaMbosiMundrabillaSikhote-AlinWillametteAnd the 25000000.csv file should look like this:Armanty Meteorite Data Processing代写Campo del CieloCanyon DiabloCape YorkGibeonHobaI recommend you run your code with other various inputs to check to make sure your code is working correctly. Confirm that your program gives expected results.Data and InformationAll data needed for the assignment is in the Meteorite_Landings.csv file. Please download this file and save itinto the same folder where you will save your .py file containing your Python code. You do not need to turn inthe .csv file. When I test your code, I will have the same exact csv file on my computer. Please make sureyour code works with a file named exactly Meteorite_Landings.csv. If your code tries to open a file named Meteorite_Landings(2).csv, for example, it will fail the test cases.The file has over thirty thousand lines, so it will take a while to open. (You should open the file forviewing by using a simple text editor like Notepad instead of a spreadsheet program like Excel.) Meteorite Data Processing代写Meteorite Data Processing代写That said, it looks like the following:name,mass (g),GeoLocationAachen,21, (50.775000, 6.083330) Aarhus,720, (56.183330, 10.233330) Abee,107000, (54.216670, -113.000000) Acapulco,1914, (16.883330, -99.900000) Achiras,780, (-33.166670, -64.950000) Adhi Kot,4239, (32.100000, 71.800000) Adzhi-Bogdo (stone),910, (44.833330, 95.166670) Agen,30000, (44.216670, 0.616670) Aguada,1620, (-31.600000, -65.233330) Meteorite Data Processing代写Aguila Blanca,1440, (-30.866670, -64.550000) Aioun el Atrouss,1000, (16.398060, -9.570280) Aïr,24000, (19.083330, 8.383330) Aire-sur-la-Lys,, (50.666670, 2.333330) Akaba,779, (29.516670, 35.050000)Note that the first line contains header information. Each line after that represents one Meteorite, andcontains its name, mass (rounded to the nearest gram), and location in (latitude, longitude). Note that thesevalues are separated by commas. The location will require some extra handling, as it is surrounded byquotes and itself has a comma in it that separates the latitude and longitude.You will use a single dictionary to store this data in your code.You will not receive full credit on this project if you do not use a dictionary for this purpose. Each key-value pair should represent a singlemeteorite. The key should be the name of the meteorite as a string. The value should be a list. Thefirst element in the list should be the mass in grams as an integer. The second element in the listshould be the latitude as a floating point value. The third element in the list should be the longitude as a floating point value. Do not store the headers in the dictionary   just the data.Some masses are unknown, and will show up as an empty string. Before storing the mass into thedictionary, you must determine if this is the case. Check and see if the section of the line containing the massis an empty string. If it is, store the mass as -1 grams. This way, if one were to process the data stored inyour dictionary, they would know right away if the mass was not recorded.Meteorite Data Processing代写Do the same for the latitude and longitude: if there is no data for the location, store the latitude andlongitude both as -1. (I realize this is not a perfect solution, but for the purposes of this assignment this is okay).RequirementsSave your file as LastnamePA07.py where Lastname is your last name.Your user interface should include the following:Output- display a welcome message and instructions for various options Tell the user to Enter 1 to look up information on a meteorite by nameTell the user to Enter 2 to create a new csv file that contains all meteorites greater than a specified massTell the user to Enter 0 to exit the program Meteorite Data Processing代写Input- the program should ask for:What the user wants to do (a number between 0 and 2)Output- the program s output will depend on what the user tells the program to do. Please see details for each function below.Your program should have (at least) three functions:Amain function that controls the flow of the program. It should: Create the dictionary that stores the meteorite dataFirstcreate an empty dictionaryThen,go though each line of the file (don t forget the first line has header information)Stripeach line to remove any extra whitespaceSpliteach line to create a list of relevant datManipulatesaid data using string operations such as slicingMeteorite Data Processing代写Savethe data into the dictionaryThekey should be the name of the meteorite as a stringThevalue should be a lis The first element in the list should be the mass in grams as aninteger. The second element in the list should be the latitude as a floating point value. Thethird element in the list should be the longitude as a floating point value.

所有的编程代写范围:essayghost为美国、加拿大、英国、澳洲的留学生提供C语言代写、代写C语言、C语言代做、代做C语言、数据库代写、代写数据库、数据库代做、代做数据库、Web作业代写、代写Web作业、Web作业代做、代做Web作业、Java代写、代写Java、Java代做、代做Java、Python代写、代写Python、Python代做、代做Python、C/C++代写、代写C/C++、C/C++代做、代做C/C++、数据结构代写、代写数据结构、数据结构代做、代做数据结构等留学生编程作业代写服务。