Write a function senatorname

Assignment Help Computer Engineering
Reference no: EM131233879

Assignment:

Data Import ­ - A

Learning Objectives

In this assignment, you will learn how to:

? read and write Excel files

? shape data

Tasks

Before diving into the programming problems, study the data file "2013 Geographic Coordinate Spreadsheet for US Farmers Markets 8'3'1013"  that is provided for the assignment:

1. Load the data file into a data frame.

2. The seasons are not standardized and would make analysis difficult. Create six levels of seasons: Summer, Fall, Winter, Spring, Year­Round, Half­Year and convert each provided season in the Season1Date column to one of the season levels. Come up with reasonable rules, for example, June to August would be Summer, while 5/1 to 10/30 would be Half­Year. You need to use string processing functions to parse the strings and shape the data into the categories. If there are missing end dates, ignore the entire row.

3. Write a retrieval function acceptsWIC() that allows a data scientist to find which markets accept WIC. The function should output a data frame containing only the markets that accept WIC. Use the function and output the data frame.

Data Import ­ - B

Learning Objectives: In this assignment, you will learn how to:

? read and parse XML

? retrieve data from XML

Tasks

1. Load the XML document at the URL

(https://www.xmldatasets.net/temp/179681356453762.xml) directly into a data frame.

2. Write a function senatorName() that returns the names of the senators for a given state, i.e., the function takes a state as an argument and returns the names of the senators for that state in a vector.

3. Write a function senatorPhone() that returns the phone number for a given senator. The function should take the first and last name of the senator as an argument, parse the name, search for a match in the data frame and return the phone number for that senator.

Be sure to call your functions to test that it works. Use local variables only and pass any information your function needs as parameters.

Data Import ­ - C

Learning Objectives: In this assignment, you will learn how to:

? read and parse XML

? retrieve data from XML

Tasks

1. Load and then parse the XML document at the URL

(https://www.cs.washington.edu/research/xmldatasets/data/auctions/ebay.xml) using xmlTreeParse() . The data sets contains bidding information about items on eBay. Create any intermediate data objects as deemed necessary to write a function named moreFiveBids() to answer the following question: how many auctions had more than 5 bids? Use the function to output the answer.

2. Take a look at the data set on trades during a single day for ESZ13 futures trades at the URL https://www.barchartmarketdata.com/data­samples/getHistory15.xml. After loading the data, write and use the following functions to answer these retrieval queries:

a. highestClosingPrice() answers the question: what was the highest closing price for the security?

b. totalVolume() answers the question: what was the total volume traded?

c. averageVolume() answers the question: what was the average trading volume during each HOUR of the trading day? The function should place the result into a data frame containing the hour and average trading volume for that hour.

Data Import ­ - D

Learning Objectives: In this assignment, you will learn how to:

? read and parse text files

Tasks

1. Load IMDB movie listing from the file movies.list.gz. Note that the file is compressed so you need to figure out how to uncompress it in R. Inspect the file and determine how to best load it ­­ this is not an XML file and requires custom string parsing. 

2. Parse the data. You should identify all the fields and their meanings within the file. Place the data into a data frame suitable for further analysis.

3. Comment your code where you identify the movie rows that are part of your result set. 

4. Your result set should only contain movie title and movie release year. Your result set should NOT include rows for TV shows. You can identify the movies within the data file (look for a special marking field or some other indication). Make any other assumptions you need, but comment your assumptions. For a cleaner result set, look for duplicate titles and remove the duplicates.

5. For correct syntax, coding style and readable code format. If the data size is overwhelming, you can build a smaller subset of the file that's easier for testing, loads faster and is representative of the file (a random sample of rows). This is a common technique when building data loaders. This technique is for debugging purposes only.

Your submitted assignment should be run against the complete data set.

Assignment Link -

https://www.dropbox.com/s/pewqshz7oylv26w/Assignment.rar?dl=0

Reference no: EM131233879

Questions Cloud

Mentoring be used for career advancement : Topic: How Can Socialization and Mentoring Be Used for Career Advancement. In 300-400 words explain how socialization and mentoring can both help minimize resistance to change.
What is the flow rate under the practical worst case : Consider the following four-workstation production line. Station Number of Machines Processing Time (hours) 1 1 0.05 2 6 0.25 3 3 0.2 4 2 0.167 1) (15 pts) What are the bottleneck rate, raw process time and critical inventory of this production line?..
The senior management team of efficient network : The senior management team of Efficient Network HMO is evaluating the year-end data related to emergency room (ER) expenses. One physician group within the network had ER expenses that were three times the rate of any other group within the network. ..
Analyze the strategy of the organization and the hr strategy : Create a list of the key HR functions that you believe will be beneficial to the organization. From the list, choose one (1) HR function that will be the focus of your business proposal moving forward. Explain the main reasons why you chose that H..
Write a function senatorname : CS6020 Assignment: Write a function senatorName() that returns the names of the senators for a given state, i.e., the function takes a state as an argument and returns the names of the senators for that state in a vector
The life of the typical organization : What is the most important role HR managers play in the life of the typical organization? What might be the most challenging aspect of performing HR's role, and how can future HR professionals specifically prepare to meet such challenges?
How non-profit organizations can do at least : 1. Discuss how businesses can do at least two of the following; support, maintain, or decrease the quality of life for society. 2. Discuss how non-profit organizations can do at least two of the following; support, maintain, or decrease the qualit..
How would you help to explain this reorganization : It seems as though we are always hearing about health services organizations and health supplier organizations that are merging, consolidating, or going out of business. How would you help to explain this reorganization? Is this reorganization eve..
Receive the packages he needs from previous workstation : Jason Carter works for a producer of soaps that come in packages of 6 each. His job is to fill the packages with soap, and he is expected to process 30 packages an hour. The facility where Jason works uses a kanban production system in which each con..

Reviews

len1233879

10/7/2016 5:59:49 AM

It has to be written like someone just beginning to learn this stuff and there needs to be comments after each line of code saying what it's doing and I need to be able to run on my own computer through my working directory which is. https://drive.google.com/file/d/0B3vV-uda2F1yUTI0dmhVTlg2RUU/view

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd