Quant 1
What are the first steps in creating a new project?
1. Go to documents and create a new folder 2. download the data file as a csv and place it in the new folder
how do you get R script?
File, New File, Data Script
What do you have to program for R studio to read the csv file you uploaded?
Filename<-read.csv
how do you program IQR
IQR(mtcars$mpg) IQR(filename$variable)
Once your project has been uploaded into R studio, what do you need to do to be able to program and type notes?
R Script
Once you have created a new project and uploaded the data set, how do you get that new project into R studio?
Select/New project Existing directory Browse--> find your new folder Create project
what is variability
amount of variance --> amount of dispersion finding out how widely variables are distributed
frequency tables are not good for continuous numbers, so what do you do?
create Bins
what do you program to create bins?
cut(mtcars$qsec,5) cut(filename$variable,numberofbinsyouwant)
what does IQR do?
gets rid of outliers 3rd quartile - 1st quartile
what do you have to program to read a larger set of data from the csv file?
head(mtcars) **mtcars is the file name
what do you use qnorm for?
it is the inverse of pnorm, which means you find the the value of the next standard deviation value.
how do you make ggplot2 useful?
library(ggplot2)
how do you program mean
mean(mtcars$mpg) mean(filename$variable)
examples of measure of central tendency
mean, median, mode
how do you program median
median(mtcars$qsec)
what is the function for qnorm?
norm(.4,mean=300,sd=24,lower.tail=FALSE)
how do you create a bar chart from ggplot2?
plot(factor(carb),data=mtcars,geom="bar") plot(factor(variable),data=filename,geom="bar")
what function do you use to find the probability in a distribution curve of a shaded area?
pnorm(290,mean=300,sd=,lower.tail=FALSE)
Sample mean is a ...
random variable, ability to move around
how do you program range
range(mtcars$mpg) range(filename$variable)
how do you program standard deviation
sd(mtcars$mpg) sd(filename$variable)
what measures variability
standard deviation
what do you program if you want the summary of univariate statistics
summary(mtcars) summary(filename)
if you want to see a frequency of a certain variable, what do you program?
table(mtcars$carb) table(filename$variable)
according to the central limit theorem what is the same between x and "x bar"
the Mean
how do you install ggplot2
tools, install packages, type ggplot2
what do you have to program to reference only one variable in the data set?
unique(mtcars$carb) unique(filename$variablename)
what is special about bins?
you can create a frequency table using the bins we created. the bins just pull similar continuous variables together so its more simple and easier to read
how do you create bar charts and histograms
you have to download and install ggplot2
how do you find the standard deviation of "x bar" based on x?
you take the standard deviation of x and divide it by the square root of n