search for: qsec

Displaying 20 results from an estimated 33 matches for "qsec".

Did you mean: nsec
2009 Jul 23
2
param:qsec in ggplot2
Hii i have been trying to do a scatter plot with ggplot2, like the plot 6 here (http://had.co.nz/ggplot2/geom_point.html) .. where the points size vary with values > p + geom_point(aes <http://had.co.nz/ggplot2/aes.html>(size = qsec)) but am not sure how to setup the parameter - qsec could anyone please give some pointers on how to define that thanks Mo. [[alternative HTML version deleted]]
2010 Jan 19
1
Model frame when LHS is cbind (PR#14189)
The model frame shows the response and predictors in a data frame with nicely labelled columns: fm <- lm(wt~qsec+log(hp)+sqrt(disp), data=mtcars) model.frame(fm) # ok When the left hand side consists of more than one response, those response variables still look good, inside a matrix: fm <- lm(cbind(qsec,hp,disp)~wt, data=mtcars) model.frame(fm)[[1]] # ok A problem arises when some of the respon...
2011 Oct 03
4
Question about ggplot2 and stat_smooth
I'm interested in creating a graphic -like- this: c <- ggplot(mtcars, aes(qsec, wt)) c + geom_point() + stat_smooth(fill="blue", colour="darkblue", size=2, alpha = 0.2) but I need to show 2 sets of bands (with different shading) using 5%, 25%, 75%, 95% limits that I specify and where the heavy blue line is the median. I don't understand how to do t...
2010 Aug 14
1
is it possible to map 2 plots(c and d) in a single output plot?
is it possible to map 2 plots(c and d) in a single output plot? library(ggplot2) c <- ggplot(mtcars, aes(qsec, wt)) d <- ggplot (mtcars, aes(qsec, wt)) c + stat_smooth(fill="darkgrey", colour="blue", size=2, alpha = 0.2) d + stat_smooth(fill="darkgrey", colour="red", size=2, alpha = 0.2) -- View this message in context: http://r.789695.n4.nabble.com/is-it-possibl...
2009 Apr 27
0
VIF's in R using BIGLM
...ation factors) from the regression output of BIGLM. Traditionally, this has been possible with the regular lm() function. Follows a quick illustration (the model below is pretty silly, only for illustration purposes). Example dataset: > mtcars mpg cyl disp hp drat wt qsec vs am gear carb Mazda RX4 21.0 6 160.0 110 3.90 2.620 16.46 0 1 4 4 Mazda RX4 Wag 21.0 6 160.0 110 3.90 2.875 17.02 0 1 4 4 Datsun 710 22.8 4 108.0 93 3.85 2.320 18.61 1 1 4 1 Hornet 4 Drive 21.4 6 258.0 110 3.08 3.215 19.44 1 0 3 1 Hornet...
2016 Apr 14
4
Bug in by() function which works for some FUN argument and does not work for others
...Qu.:116.5 Median :17.30 Median :8.000 Median :275.8 Median :175.0 Mean :17.15 Mean :6.947 Mean :290.4 Mean :160.3 3rd Qu.:19.20 3rd Qu.:8.000 3rd Qu.:360.0 3rd Qu.:192.5 Max. :24.40 Max. :8.000 Max. :472.0 Max. :245.0 drat wt qsec vs am Min. :2.760 Min. :2.465 Min. :15.41 Min. :0.0000 Min. :0 1st Qu.:3.070 1st Qu.:3.438 1st Qu.:17.18 1st Qu.:0.0000 1st Qu.:0 Median :3.150 Median :3.520 Median :17.82 Median :0.0000 Median :0 Mean :3.286 Mean :3.769 Me...
2016 Apr 14
0
Bug in by() function which works for some FUN argument and does not work for others
I think you are not using the best function for what your intentions are. Try: > by(data=mtcars, INDICES=list(as.factor(mtcars$am)), FUN=colMeans) : 0 mpg cyl disp hp drat wt qsec vs 17.1473684 6.9473684 290.3789474 160.2631579 3.2863158 3.7688947 18.1831579 0.3684211 am gear carb 0.0000000 3.2105263 2.7368421 --------------------------------------------------------------------------- : 1 mpg cyl disp...
2016 Apr 15
4
Bug in by() function which works for some FUN argument and does not work for others
...a.adrian at unibuc.ro> wrote: > I think you are not using the best function for what your intentions are. > Try: > > > by(data=mtcars, INDICES=list(as.factor(mtcars$am)), FUN=colMeans) > : 0 > mpg cyl disp hp drat wt > qsec vs > 17.1473684 6.9473684 290.3789474 160.2631579 3.2863158 3.7688947 > 18.1831579 0.3684211 > am gear carb > 0.0000000 3.2105263 2.7368421 > > --------------------------------------------------------------------------- > : 1 >...
2007 Sep 20
1
ggplot and xlim/ylim
Hello everyone, I am (happily) using ggplot2 for all my plotting now and I wondered is there is an easy way to specify xlim and ylim somewhere when using the ggplot syntax, as opposed to the qplot syntax. Eg. qplot(data=mtcars,y=wt, x=qsec,xlim=c(0,30)) <-> ggplot(mtcars, aes(y=wt, x=qsec)) + geom_point() + ??? Indeed the ggplot syntax is in general more flexible and powerful and I usually rely on it in scripts. It would be nice to know how to use xlim/ylim with this syntax. Thank you in advance. JiHO --- http://jo.iri...
2020 Oct 18
1
Resultado de la consola como un tibble
...t(value)$statistic) , by = .(variable)] variable p_value v_stat 1: mpg 1.228814e-01 0.9475647 2: cyl 6.058338e-06 0.7533100 3: disp 2.080657e-02 0.9200127 4: hp 4.880824e-02 0.9334193 5: drat 1.100608e-01 0.9458839 6: wt 9.265499e-02 0.9432577 7: qsec 5.935176e-01 0.9732509 8: vs 9.737376e-08 0.6322635 9: am 7.836354e-08 0.6250744 10: gear 1.306844e-05 0.7727856 11: carb 4.382405e-04 0.8510972 Saludos, Carlos Ortega www.qualityexcellence.es El dom., 18 oct. 2020 a las 11:53, Carlos Ortega (<cof en qualityexcellence.e...
2020 Oct 18
2
Resultado de la consola como un tibble
Buen día estimados Estoy tratando de hacer un tibble con los resultados de un apply que se muestran en la consola que me da R, no estoy seguro si eso se pueda hacer, pero me gustaría organizar los resultados de esa manera. mi código es: data("mtcars") Mtcars_matriz <- as.matrix(mtcars) apply(Mtcars_matriz, MARGIN =2, FUN = shapiro.test) DF2 <- tibble(Variable = NA, W = NA, Pvalue =
2016 Apr 15
0
Bug in by() function which works for some FUN argument and does not work for others
...: > >> I think you are not using the best function for what your intentions are. >> Try: >> >>> by(data=mtcars, INDICES=list(as.factor(mtcars$am)), FUN=colMeans) >> : 0 >> mpg cyl disp hp drat wt >> qsec vs >> 17.1473684 6.9473684 290.3789474 160.2631579 3.2863158 3.7688947 >> 18.1831579 0.3684211 >> am gear carb >> 0.0000000 3.2105263 2.7368421 >> >> --------------------------------------------------------------------...
2016 Apr 16
2
Bug in by() function which works for some FUN argument and does not work for others
...ot using the best function for what your intentions > are. > >> Try: > >> > >>> by(data=mtcars, INDICES=list(as.factor(mtcars$am)), FUN=colMeans) > >> : 0 > >> mpg cyl disp hp drat wt > >> qsec vs > >> 17.1473684 6.9473684 290.3789474 160.2631579 3.2863158 3.7688947 > >> 18.1831579 0.3684211 > >> am gear carb > >> 0.0000000 3.2105263 2.7368421 > >> > >> > ----------------------------------...
2013 Apr 12
3
Why copying columns of a data.frame becomes numeric?
...olumns become numeric class rather than data frame. But, when I copy rows, they data frame retains its class. Why is this? I don't see why copying rows vs columns is so different. > class(mtcars) [1] "data.frame" > head(mtcars) mpg cyl disp hp drat wt qsec vs am gear carb Mazda RX4 21.0 6 160 110 3.90 2.620 16.46 0 1 4 4 Mazda RX4 Wag 21.0 6 160 110 3.90 2.875 17.02 0 1 4 4 Datsun 710 22.8 4 108 93 3.85 2.320 18.61 1 1 4 1 Hornet 4 Drive 21.4 6 258 110 3.08 3.215 19.44 1 0 3 1 Hornet...
2012 Nov 04
1
Apply same linear model to subset of dataframe
...example using a for loop, a function or plyr) to achieve the same output as below? data(mtcars) # Apply the same model to the dataset but choosing different combinations of dependent (DV) and independent (IV) variables in each case: lm.mpg= lm(mpg~cyl+disp+hp, data=mtcars) lm.drat = lm(drat~wt+qsec, data=mtcars) lm.gear = lm(gear~carb+hp, data=mtcars) # Plot residuals against fitted values for each model plot(lm.mpg$fitted,lm.mpg$residuals, main = "lm.mpg") plot(lm.drat$fitted,lm.drat$residuals, main = "lm.drat") plot(lm.gear$fitted,lm.gear$residuals, main = "lm.gear...
2016 Apr 17
0
Bug in by() function which works for some FUN argument and does not work for others
...are not using the best function for what your intentions are. > >> Try: > >> > >>> by(data=mtcars, INDICES=list(as.factor(mtcars$am)), FUN=colMeans) > >> : 0 > >> mpg cyl disp hp drat wt > >> qsec vs > >> 17.1473684 6.9473684 290.3789474 160.2631579 3.2863158 3.7688947 > >> 18.1831579 0.3684211 > >> am gear carb > >> 0.0000000 3.2105263 2.7368421 > >> > >> ---------------------------------------...
2017 Aug 29
2
DBI::dbWriteTable syntax error apparently from quotes
...) When I try this I get the following error Error: <SQL> 'CREATE TABLE "mtcars" ( "row_names" varchar(255), "mpg" FLOAT, "cyl" FLOAT, "disp" FLOAT, "hp" FLOAT, "drat" FLOAT, "wt" FLOAT, "qsec" FLOAT, "vs" FLOAT, "am" FLOAT, "gear" FLOAT, "carb" FLOAT ) ' nanodbc/nanodbc.cpp:1587: 42000: [FreeTDS][SQL Server]Incorrect syntax near 'mtcars'. I believe that the complaint is related to the double quotes around "mtcars&q...
2020 Oct 18
0
Resultado de la consola como un tibble
...65696108598 disp.p.value 0.920012680133146 disp.statistic.W 14 0.0488082381051741 hp.p.value 0.93341934019855 hp.statistic.W 18 0.110060757426683 drat.p.value 0.945883896521269 drat.statistic.W 22 0.0926549888932132 wt.p.value 0.943257719087817 wt.statistic.W 26 0.593517649295161 qsec.p.value 0.973250948857977 qsec.statistic.W 30 9.73737573091618e-08 vs.p.value 0.632263534949347 vs.statistic.W 34 7.83635448813453e-08 am.p.value 0.625074366031524 am.statistic.W 38 1.30684376520844e-05 gear.p.value 0.772785633173186 gear.statistic.W 42 0.000438240495931375 carb.p.value 0.8...
2012 Nov 19
2
lattice: defining grouping variable only for the upper/lower panel with splom
Using the mtcars dataset, how to define the grouping variable to be valid only for the upper or lower panel? The following doesn't work: # Code start splom(~data.frame(mpg, disp, hp, drat, wt, qsec), data=mtcars, pscales=0, auto.key=list(columns=3), upper.panel = function(...){ panel.grid(...) panel.xyplot(groups=cyl,...) } ) # Code end -- View this message in context: http://r.789695.n4.nabble.com/lattice-defining-grouping-variable-only-for-the-upp...
2010 Aug 12
2
drawing dot plots with size, shape affecting dot characteristics
Hi all, I'm interested in doing a dot plot where *both* the size and color (more specifically, shade of grey) change with the associated value. I've found examples online for ggplot2 where you can scale the size of the dot with a value: http://had.co.nz/ggplot2/graphics/6a053f23cf5bdfe5155ab53d345a5e0b.png Or scale the color with the value: