1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
DochEvi [55]
3 years ago
14

In Lab 7, we worked through a program that displayed the homeless shelter occupancy over time. The same approach can be used for

displaying any dataset where the date and time are stored. For this program, use the lab as a starting point to display public school attendance from NYC OpenData. If you would like to test your program on other data, you can filter for an individual school by viewing the data and filtering on the school number ("School DBN"). Export the file as CSV and save. There is a sample file for the high school on campus on github Modify the program from Lab 7 that displays shelter population over time to: Ask the user to specify the input file, Ask the user to specify the output file, Convert the date column (which is stored as 'YYYYMMDD') to a datetime format recognized by pandas, for example if your dataframe is df, overwrite the 'Date' column to be: df["Date"] = pd.to_datetime(df["Date"].apply(str)) Make a plot of the percent of absent students over time from the data in the input file, and Store the plot in the output file the user specified. A sample run of the program: Enter name of input file:

Engineering
1 answer:
Bezzdna [24]3 years ago
6 0

Answer:

Explanation:

The python code to generate this is quite simple to run.

i hope you understand everything written here, you can as well try out other problems to understand better.

First to begin, we import the package;

Code:

import pandas as pd

import matplotlib.pyplot as plt

name = input('Enter name of the file: ')

op = input('Enter name of output file: ')

df = pd.read_csv(name)

df['Date'] = pd.to_datetime(df["Date"].apply(str))

plt.plot(df['Date'],df['Absent']/(df['Present']+df['Absent']+df['Released']),label="% Absent")

plt.legend(loc="upper right")

plt.xticks(rotation=20)

plt.savefig(op)

plt.show()

This should generate the data(plot) as seen in the uploaded screenshot.

thanks i hope this helps!!!

You might be interested in
typedef struct bitNode { int data; struct bitNode *left; struct bstNode *right; } bstNode; int solve(bstNode* root) { if (root =
Sergio039 [100]

Answer:

The ten numbers to be filled in the blanks are: 18, 7, 7, 11, 18, 36, 3, 8, 13, 50.

Explanation:

keeps on going to the left node until node->left == NULL;

now at Node 18;

left = right = 0; hence condition is not satisfied

18 is printed first.

the value 18 is returned .

Then we reach at 4;

from there we move to 7;

just like 18, similar things happen with 7 and 7 is printed, the value 7 is returned.

Now coming to Node 4,

left = 0, right = 7 ; hence the condition is satisfied & res = 7; 7 is printed.

For Node 16, left = 7 ; right = 11(but for this we visit 11 first and 11 is printed)

for 16; condition is satisfied; res = 7 + 11 = 18 ; 18 is printed

Now for 5; left = right = 18; the condition is satisfied; so res = 18 + 18 = 36; 36 is printed

Next we visit Node 3; 3 is printed & 3 is returned

Then Node 8 ; 8 is printed & 8 is returned

for Node 13; left = 3, right = 8 ; condition is not satisfied, 13 is printed.

For Node 50; left = 36 right = 13 ; condition is not satisfied hence 50 is printed.

So the order of printing is  18 7 7 11 18 36 3 8 13 50.

4 0
3 years ago
A 7-hp (shaft) pump is used to raise water to an elevation of 15 m. If the mechanical efficiency of the pump is 82 percent, dete
Natali [406]

The maximum volume flow rate of water is determined as 0.029 m³/s.

<h3>Power of the pump</h3>

The power of the pump is watt is calculated as follows;

1 hp = 745.69 W

7 hp = ?

= 7 x 745.69 W

= 5,219.83 W

<h3>Mass flow rate of water</h3>

η = mgh/P

mgh = ηP

m = ηP/gh

m = (0.82 x 5,219.83)/(9.8 x 15)

m = 29.12 kg/s

<h3>Maximum volume rate</h3>

V = m/ρ

where;

  • ρ is density of water = 1000 kg/m³

V = (29.12)/(1000)

V = 0.029 m³/s

Learn more about volume flow rate here: brainly.com/question/21630019

#SPJ12

5 0
2 years ago
What does it mean when it says technology is A dynamic process
Degger [83]

Answer:

It studies the process of technological change. Under the field of Technology Dynamics the process of technological change is explained by taking into account influences from "internal factors" as well as from "external factors

Explanation:

5 0
3 years ago
When you arrive at an intersection with a stop sign in your direction, if there is no marked stop
Illusion [34]

Answer:

C: Stop before entering the pedestrian crosswalk.

Explanation:

3 0
3 years ago
Read 2 more answers
Lynx eat snowshoe hares, and snowshoes hears eat plants. Which term can be applied to the lynx in this food chain example? Prima
erastova [34]

Answer:

primary consumer because YES

3 0
2 years ago
Other questions:
  • Consider an InSb NW with ballistic mean free path of 150nm. Calculate the current through a 250nm long InSb NW when a 100mV bias
    6·1 answer
  • What is the correct statement regarding the stress over the section of a shaft in torsion?
    13·1 answer
  • Write a function named is_float(s) that takes one argument that is a string. It returns True if string s represents a floating p
    6·1 answer
  • Which of the following units of measurement is denoted by a single apostrophe mark (')?
    6·1 answer
  • A manager who focuses on the employees who enable a company to do business is human resource management. True True False False
    7·1 answer
  • Consider a machine of mass 70 kg mounted to ground through an isolation system of total stiffness 30,000 N/m, with a measured da
    9·1 answer
  • Technician A says that acid core solder should be used whenever aluminum wires are to be soldered.
    14·1 answer
  • Bob would like to run his house off the grid, therefore he needs to find out how many solar panels and batteries he needs to buy
    12·1 answer
  • There are three different types of slings. What determines which type you use?
    13·1 answer
  • The following is a series of questions pertaining to the NSPE Code of Ethics. Please indicate whether the statement are true or
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!