hello guys , im a med student and I was asked to do a project in rscript , so I searched for a data and i found cars data , i made the script but the problem is that the output looks very unorganized
as you can see in the picture there is no space between each column , is there a way to do it better ?
here is the script :
Make<- c("BMW","BMW","BMW","BMW","BMW","BMW","BMW","BMW","BMW","BMW","BMW"
,"BMW","BMW","BMW","BMW","BMW","BMW","Audi","Audi","Audi","Audi",
"Audi","Audi","Audi","Audi","Audi","Audi","Audi","Audi","Audi")
Model <- c("1Series","1Series","1Series","1Series","1Series","1Series","1Series","1Series","1Series",
"1Series","1Series","1Series","1Series","1Series","1Series","1Series","1Series","100","100"
,"100","100","100","100","100","100","100","100","100","100","100")
Year <- c("2011","2011","2011","2011","2011","2012","2012","2012","2012","2013","2013","2013","2013",
"2013","2013","2013","2013","1992","1992","1992","1992","1992","1993","1993","1993","1993","1993","1994","1994","1994")
Fuel <- c("premium","premium","premium","premium","premium","premium","premium","premium","premium",
"premium","premium","premium","premium","premium","premium","premium","premium","regular",
"regular","regular","regular","regular","regular","regular","regular","regular","regular","regular","regular","regular")
HP <- c("335","300","300","230","230","230","300","300","230","230","300","230",
"300","230","230","320","320","172","172","172","172","172","172","172","172","172","172","172","172","172")
Cylinders <- c("6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6","6")
Transmission <- c("MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL",
"MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","MANUAL","AUTOMATIC","MANUAL","MANUAL","MANUAL","AUTOMATIC","MANUAL","MANUAL","MANUAL","AUTOMATIC","MANUAL","MANUAL")
highwayMPG <- c("26","28","28","28","28","28","26","28","28","27","28","28","28","28","28","25","28","24","24","20","24","21","24","20","24","24","21","21","22","22")
cityMPG <- c("19","19","20","18","18","18","17","20","18","18","20","19","19","19","19","18","20","17","17","16","17","16","17","16","17","17","16","16","16","17")
Popularity <- c("3916","3916","3916","3916","3916","3916","3916","3916","3916","3916","3916","3916","3916","3916","3916","3916","3916","3105","3105","3105","3105",
"3105","3105","3105","3105","3105","3105","3105","3105","3105")
MSRP <- c("46135","40650","36350","29450","34500","31200","44100","39300","36900","37200","39600","31500","44400","37200","31500","48250"
,"43550","2000","2000","2000","2000","2000","2000","2000","2000","2000","2000","2000","2000","2000")
cars.data <- data.frame(Make,Model,Year,Fuel,HP,Cylinders,Transmission,highwayMPG,cityMPG,Popularity,MSRP)
highwaycityMPG <- data.frame(highwayMPG,cityMPG)