Stats 101A HW1
.Rmd
keyboard_arrow_up
School
University of California, Los Angeles *
*We aren’t endorsed by this school
Course
101A
Subject
Statistics
Date
Jan 9, 2024
Type
Rmd
Pages
2
Uploaded by ucladsp
---
title: "Stats 101A HW1"
author: 'Ian Zhang, UID: 205702810'
date: "4/5/2023"
output:
pdf_document: default
html_document: default
---
## Question 1
```{r Question 1}
library(tidyverse)
library(lubridate)
chi <- read.csv("chicagotaxiraw.csv")
chi1<- chi %>% select('Trip.ID', 'Taxi.ID', 'Trip.Start.Timestamp', 'Trip.End.Timestamp', 'Trip.Seconds', 'Trip.Miles', 'Fare', 'Tips', 'Tolls', 'Extras', 'Trip.Total', 'Payment.Type','Company') %>% rename(trip.id = 'Trip.ID', taxi.id = 'Taxi.ID', trip.start.timestamp = 'Trip.Start.Timestamp', trip.end.timestamp = 'Trip.End.Timestamp', trip.seconds = 'Trip.Seconds', trip.miles = 'Trip.Miles', fare = 'Fare', tips = 'Tips', tolls = 'Tolls', extras = 'Extras', trip.total = 'Trip.Total', payment.type = 'Payment.Type', company = 'Company')
```
## Question 2
```{r Question 2}
endDate <- as.Date((chi1$trip.end.timestamp), format = "%Y-%m-%d %H:%M:%S")
#First pickup
max(endDate, na.rm=TRUE)
#Last pickup
min(endDate, na.rm = TRUE)
```
## Question 3
```{r Question 3}
table(wday(as.Date((chi1$trip.start.timestamp), format = "%Y-%m-%d %H:%M:%S")))
max(table(wday(as.Date((chi1$trip.start.timestamp), format = "%Y-%m-%d %H:%M:
%S"))))
#Saturday has the greatest number of trips begin with 16767 trips
min(table(wday(as.Date((chi1$trip.start.timestamp), format = "%Y-%m-%d %H:%M:
%S"))))
#Tuesday has the least number of trips begin with 12406
```
## Question 4
``` {r Question 4}
fix <- function(x){
x2 <- gsub("\\$","",x)
as.numeric(as.character(gsub(",", "", x2)))
}
tip <- sapply(chi1$tips, fix)
summary(tip)
hist(tip)
#The mean amount of a tip is $1.15, but the median is $0.00. It is better to report
the median #rather than the mean, since the data is extremely skewed,
#and has outliers that pull the mean away from what the typical tip amount is, thus
the typical #tip amount would be $0.00
```
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help
Related Questions
reference and terminal point of 13pi/4
arrow_forward
afari
File Edit
Citation list 3/11/2023...
Z=
View History Bookmarks Window Hellp
where z =
A https://www.asm.org...
https://www.michigan...
mth-webwork.se.cmich.edu
Account | Central Mic...
3
x³x3 = x²
3
(x²³ ) ³ = x^²
arrow_forward
Ssin (dB
audui
arrow_forward
Define Clairaut equation?
arrow_forward
Salve
5/12
usup UI=t3cost, Usafisint
arrow_forward
O Copy of Algebra I Final Exam - G x
adocs.google.com/presentation/d/1ry04WKcCUYeulWtAru6SI1tYvzw6sP4PualkrbstAg/edit?ts=60747a30#slide-id.gb05bbbec93_26 68
f Algebra I Final Exam
: View Insert Format Slide Arrange Tools Add-ons Help
%23
Last edit was seconds ago
IT
O Present
Background Layout-
Theme
Transition
M 1 I 2 I 3 I 4 I S E 7
..B ...I .. 9. ..E
Standard 2: Line of Best Fit
#1 of 1
# of
# of
A. Write the equation of the line of best fit(from Desmos.com-instructions HERE
Students
students
that like
responded Math
that
B. Using your line of best fit equation, predict the number of students that like
Math if 1000 students responded. SHOW WORK with your equation and round
down to the nearest person.
30
24
41
31
C. If you found that 200 students like Math, how many students responded?
SHOW WORK with your equation and round up to the nearest person!
80
68
100
85
110
94
D. Predict the number of students that like Math if 25,000 students were
surveyed. SHOW WORK with your equation!
150…
arrow_forward
FBCA 1n1vgK72E-ta9cMZjU5PczCLF
WSGW/edit#slide=id.gbd70b364199_0_12
- Decimal Word Problems +- x/
D Present
2 Share
ange Tools Add-ons Help
Last
Creating images.
Background
Layout-
Theme
Transition
3
I 6 I 7
8.
The wings of a ruby-throated hummingbird beat an
average of 52 times per second. If a ruby -throated
hummingbird hovers for 35.5 seconds, on average how
many times does its wings beat?
notes
arrow_forward
Jassessment/take/take.jsp?course_assessment_id%3_51315_1&course_id%3_39532_1&content_id%= 485434_1&question_num_12.x=D0&toggle_
Remaining Time: 1 hour, 13 minutes, 14 seconds.
* Question Completion Status:
10
2
3D
10
11
12
A Click Submit to complete this assessment.
Question 12
2.
For what value of t , if any, is the vector ( 2t, -1)
parallel to the vector (4, -1) ?
No t
OA'
OB t=8
ocT= - 2
ODt=2
A Click Submit to complete this assessment.
Save and
G 4 A
arrow_forward
I’m really confused
arrow_forward
Module 13 Lecture Materials - MX
WAHomework 9.1 and 9.3-9.6 MAT X
webassign.net/web/Student/Assignment-Responses/submit?pos=3&dep3=23136141.. *
© NP IU
pps
history 1302 book bio MATH 1342, sectio...
psychology k kanopy
ur best submission for each question part is used for your score.
-/3.09 POINTS
ILLOWSKYINTROSTAT1 9.PR.034.
MY NOTES
ASK YOUR TEACHER
The probability of winning the grand prize at a particular carnival game is 0.005. Michele wins the grand prize. Is this
considered a rare or common event? Why?
This is considered a common event because the probability of it occurring is so high.
This is considered a rare event because the probability of it occurring is so high.
This is considered a common event because the probability of it occurring is so low.
This is considered a rare event because the probability of it occurring is so low.
Additional Materials
eBook
Submit Answer
View Previous Question
Question 5 of 11
View Next Question
Home
My Assignments
+Request Extension…
arrow_forward
Please fill in the information for step 2 and use it to solve for the final answer.
arrow_forward
sec4 dx
arrow_forward
sec" Vn du
arrow_forward
5
arrow_forward
The expression of Absorption's law is given by what?
arrow_forward
1- Online State- X
https://www.usatestprep.com/modules/questions/qq.php?testid313088&assignment_id%3D42092601&stran.. Q☆
1
Submit
In baseball, the pitcher's mound is 60.5 feet from home plate. If the fastest pitch ever recorded in Major League Baseball was 105.1
miles per hour, how many seconds did it take for the ball to travel from the pitcher's mound to home plate? Round the answer to the
nearest tenth.
A)
0.4 seconds
3)
0.8seconds
1.2seconds
16seconds
Cuantres
国
arrow_forward
e learn-us-east-1-prod-fleet02-xythos.content.blackboardcdn.com
+
Bb https://learn-us-east-1-prod-fleet02-xythos.content.blackboardcdn.com/5d44406cac91b/264693142?X-Blackboard-Expiration=1635400800000&X-Blackboard-Signature.
b My Questions | bartleby
Find the system of equations to model the problem. DO NOT SOLVE THIS SYSTEM.
9) A $124,000 trust is to be invested in bonds paying 9%, CDs paying 8%, and mortgages paying 10%. 1 9)
sum of the amount invested in bonds and the amount invested in CDs must equal the mortgage
investment. To earn an $11,400 annual income from the investments, how much should the bank inv
each?
Let x represent the amount invested in bonds, y the amount invested in CDs, and z the amount inve:
mortgages.
A) x + y - z = 11,400
x - y + 9z = 22
8х + у +z%3D 124,000
С) х +у -Z3D0
x + y + z = 124,000
0.09x + 0.08y + 0.1z = 11,400
В) х + у-z%3D0
X + y + z = 124,000
9x + 8y + z = 11,400
D) x + y + z = 0
x + y - 9z = 124,000
0.1x + 0.08y - 0.09z= 11,400
10)
10) There were…
arrow_forward
how to use the apr approximation formula
arrow_forward
A dolphin is swimming 18 feet below the surface of the ocean There is a coast guard helicopter 75.5 above the surface of the water that is directly above the dolphin what is the distance between the dolphin and the helicopter
arrow_forward
Chrome
Archivo
Editar
Ver
Historial
Favoritos
Perfiles
Pestaña
Ventana
Ayuda
BE BE
A bbhosted.cuny.edu/webapps/assessment/take/launch.jsp?course_assessment_id=_2002402_1&course_id%=_2050858_1&content_id%3_60703...
Aplicaciones
M Gmail
YouTube
A Maps
Noticias
Traducir
Question Completion Status:
The amount of water consumed each week by Bronx residences is normally distributed. The population mean of water consumption is 120.3 gallons with a
standard deviation of 10.0 gallons. Test the claim at the 0.10 significance level that the average amount of water consumed is not 125 gallons with a sample
size of 100 residences.
What is the z obr? (round to the nearest tenth)
QUESTION 7
arrow_forward
gebra Il-P1 S2
- Launch Meeting -Zoom
6 Google Drive LTI
O Google Drive LTI
2. va.us/gb_StudentAssessment.aspx?SID=28205&STID=7893&NP=1
6 Google Drive LTI
TumingPoint-Parti.
Roots, Multi, and Fu..
4 Roots, Multi, and Fu.
Roots, Multi, and Fu. 6
& 7 (S2)- VIRTUAL
#11 of 15 -
If f(x) = x - 4 and g(x) = -2x² + 3 , which polynomial is equivalent to g(f(x))?
A
-2x2 - 16x + 35
-2x3 + 8x2 + 3x – 12
-2x2 + 16x – 29
-2x2 – 1
(10
Save
12
arrow_forward
Image attached with question
arrow_forward
1970
Q320
Answ
b 010
Bb Q10(1 E
Ims.jazanu.edu.sa/bbcswebdav/pid-796204-dt-content-rid-22853742 1/courses/362MATH-3_31 08768 01 501_20212/Q10%281%25
dai A
view-source:https://..6
Google bilys YouTube
Gmail M
Juraig i
100%
1/1
The bob of a 4 m pendulum describes an arc of circle in a vertical plane. If
the tension in the cord is 5.0 times the weight of the bob for the position
shown, find the velocity and the acceleration of the bob in that position.
4 m
30°
m
Q6(1) 1111111111.pdf 2
Sigic.webp
arrow_forward
questions 12 AND 13 PLEASE
arrow_forward
naining Time: 3 hours, 23 minutes, 18 seconds.
✓ Question Completion Status:
Type of Job
000 000
White Collar
Blue Collar
43%
95%
28%
37%
91%
41%
Republican
11%
15%
26%
sessment_id= 415098_1&course_id= 309271_1&new_attempt=1&c...
Political
Democrat
21%
16%
37%
Affiliation
Independent Total
42%
58%
100%
10%
27%
37%
1. Find (Probability of Blue Collar | Democrat) Use two decimal places in
your answer.
Click Save and Submit to save and submit. Click Save All Answers to save all answers.
Save All Answers
0 Guest
arrow_forward
Chrome
Archivo
Editar
Ver
Historial
Favoritos
Perfiles
Pestaña
Ventana
Ayuda
Bb
Bb Bb Bb BbSBb Bb Bb Bb Bb
A bbhosted.cuny.edu/webapps/assessment/take/launch.jsp?course_assessment_id%3_2002398_1&course_id=_2050858_1&content_id%=D_
Aplicaciones M Gmail
YouTube
Maps
Noticias
Traducir
* Question Completion Status:
A health researcher read that a 150-pound college-aged, male can burn an average of 530 calories per hour playing tennis with a standard deviation of 25
calories. 40 college-aged males were randomly selected at a commuter school and the mean number of calories burned per hour playing tennis was 540
calories.
Do college-aged male tennis players at the commuter school burn more calories per hour than the college-aged,male tennis player population?
Test with a 0.05 significance level.
What is the probability of Z obr? (round to nearest hundredth)
arrow_forward
In Exercises 25-34, find an equation of the tangent line at the point speci-
fied.
arrow_forward
Earth's E X
Investiga X
X OMƏUOH
pard.tuhsd.org/webapps/assessment/take/launch.jsp?course_ass
* Question Completion Status:
QUESTION 4
2
3.
O 42
48
O 52
O 34
QUESTION 5
12
arrow_forward
SEE MORE QUESTIONS
Recommended textbooks for you
Algebra & Trigonometry with Analytic Geometry
Algebra
ISBN:9781133382119
Author:Swokowski
Publisher:Cengage
Glencoe Algebra 1, Student Edition, 9780079039897...
Algebra
ISBN:9780079039897
Author:Carter
Publisher:McGraw Hill
Related Questions
- reference and terminal point of 13pi/4arrow_forwardafari File Edit Citation list 3/11/2023... Z= View History Bookmarks Window Hellp where z = A https://www.asm.org... https://www.michigan... mth-webwork.se.cmich.edu Account | Central Mic... 3 x³x3 = x² 3 (x²³ ) ³ = x^²arrow_forwardSsin (dB auduiarrow_forward
- Define Clairaut equation?arrow_forwardSalve 5/12 usup UI=t3cost, Usafisintarrow_forwardO Copy of Algebra I Final Exam - G x adocs.google.com/presentation/d/1ry04WKcCUYeulWtAru6SI1tYvzw6sP4PualkrbstAg/edit?ts=60747a30#slide-id.gb05bbbec93_26 68 f Algebra I Final Exam : View Insert Format Slide Arrange Tools Add-ons Help %23 Last edit was seconds ago IT O Present Background Layout- Theme Transition M 1 I 2 I 3 I 4 I S E 7 ..B ...I .. 9. ..E Standard 2: Line of Best Fit #1 of 1 # of # of A. Write the equation of the line of best fit(from Desmos.com-instructions HERE Students students that like responded Math that B. Using your line of best fit equation, predict the number of students that like Math if 1000 students responded. SHOW WORK with your equation and round down to the nearest person. 30 24 41 31 C. If you found that 200 students like Math, how many students responded? SHOW WORK with your equation and round up to the nearest person! 80 68 100 85 110 94 D. Predict the number of students that like Math if 25,000 students were surveyed. SHOW WORK with your equation! 150…arrow_forward
- FBCA 1n1vgK72E-ta9cMZjU5PczCLF WSGW/edit#slide=id.gbd70b364199_0_12 - Decimal Word Problems +- x/ D Present 2 Share ange Tools Add-ons Help Last Creating images. Background Layout- Theme Transition 3 I 6 I 7 8. The wings of a ruby-throated hummingbird beat an average of 52 times per second. If a ruby -throated hummingbird hovers for 35.5 seconds, on average how many times does its wings beat? notesarrow_forwardJassessment/take/take.jsp?course_assessment_id%3_51315_1&course_id%3_39532_1&content_id%= 485434_1&question_num_12.x=D0&toggle_ Remaining Time: 1 hour, 13 minutes, 14 seconds. * Question Completion Status: 10 2 3D 10 11 12 A Click Submit to complete this assessment. Question 12 2. For what value of t , if any, is the vector ( 2t, -1) parallel to the vector (4, -1) ? No t OA' OB t=8 ocT= - 2 ODt=2 A Click Submit to complete this assessment. Save and G 4 Aarrow_forwardI’m really confusedarrow_forward
- Module 13 Lecture Materials - MX WAHomework 9.1 and 9.3-9.6 MAT X webassign.net/web/Student/Assignment-Responses/submit?pos=3&dep3=23136141.. * © NP IU pps history 1302 book bio MATH 1342, sectio... psychology k kanopy ur best submission for each question part is used for your score. -/3.09 POINTS ILLOWSKYINTROSTAT1 9.PR.034. MY NOTES ASK YOUR TEACHER The probability of winning the grand prize at a particular carnival game is 0.005. Michele wins the grand prize. Is this considered a rare or common event? Why? This is considered a common event because the probability of it occurring is so high. This is considered a rare event because the probability of it occurring is so high. This is considered a common event because the probability of it occurring is so low. This is considered a rare event because the probability of it occurring is so low. Additional Materials eBook Submit Answer View Previous Question Question 5 of 11 View Next Question Home My Assignments +Request Extension…arrow_forwardPlease fill in the information for step 2 and use it to solve for the final answer.arrow_forwardsec4 dxarrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Algebra & Trigonometry with Analytic GeometryAlgebraISBN:9781133382119Author:SwokowskiPublisher:CengageGlencoe Algebra 1, Student Edition, 9780079039897...AlgebraISBN:9780079039897Author:CarterPublisher:McGraw Hill
Algebra & Trigonometry with Analytic Geometry
Algebra
ISBN:9781133382119
Author:Swokowski
Publisher:Cengage
Glencoe Algebra 1, Student Edition, 9780079039897...
Algebra
ISBN:9780079039897
Author:Carter
Publisher:McGraw Hill