similar to: Calculating sum of squares from density estimates

Displaying 20 results from an estimated 4000 matches similar to: "Calculating sum of squares from density estimates"

2008 Jan 26
2
using facet_grid() from ggplot2 with additional text in labels
Hi I am using ggplot2 at the moment and I must say it is definitely better then ggplot - good work. My problem is that I am using facet_grid() in the following way: > p <- ggplot(ssq, aes(x=year, y=-log(ssq))) > p + geom_point() + facet_grid(me*gi~cs*rz) and it works nicely, except that I would like to have, in naddition to the values of me, gi, cs and rz the name of the variable.
2005 Nov 24
2
type III sums of squares in R
Hi everyone, Can someone explain me how to calculate SAS type III sums of squares in R? Not that I would like to use them, I know they are problematic. I would like to know how to calculate them in order to demonstrate that strange things happen when you use them (for a course for example). I know you can use drop1(lm(), test="F") but for an lm(y~A+B+A:B), type III SSQs are only
2009 Mar 18
2
geometric mean of probability density functions
Hi, This is my first time posting to the mailing list, so if I'm doing something wrong, just let me know. I've taken ~1000 samples from 8 biological replicates, and I want to somehow combine the density functions of the replicates. Currently, I can plot the density function for each biological replicate, and I'd like to see how pool of replicates compares to a simulation I conducted
2015 Mar 02
2
R-devel does not update the C++ returned variables
Hi, Within my R code, I am using a C++ function as below: overlaps <- matrix(0, nrow=B, ncol=length(N)) overlaps.P <- matrix(0, nrow=B, ncol=length(N)) .C("speedUp", D, S, pD, pS, nrow(D), as.integer(N), length(N), ssq[i], i, as.integer(B), overlaps, overlaps.P, DUP=FALSE) the function "speedUp", is supposed to update matrices overlaps
2015 Mar 02
2
R-devel does not update the C++ returned variables
Thanks! I went through the online posts which supports the power of .Call over .C. But my probably naive question is why does this work for my code with R but not R-devel? And another question is related to using .Call. Based on the manual page, I do not need to change the function parameters when using .Call. So I can run like this: .Call("sppedUp", D, S, pD, pS, nrow(D), as.integer(N),
2002 Jun 08
3
contour plot for non-linear models
Hello all, I've tried to reproduce the contour plot that appears in the book of Venables and Ripley, at page 255. Is a F-statistic surface and a confidence region for the regression parameters of a non-linear model. It uses the stormer data that are in the MASS package. I haven't been able to reproduce the plot either in R ( version 1.5 ) and S. It makes the axes and it puts the
2002 Oct 31
1
Re: gregmisc version 0.7.3 now available
Dear Greg, Thanks for the new release. The decomposition of the SSQ is just what I need! Regards, Martin. Martin Hoyle, School of Life and Environmental Sciences, University of Nottingham, University Park, Nottingham, NG7 2RD, UK Webpage: http://myprofile.cos.com/martinhoyle >>> gregory_r_warnes at groton.pfizer.com 10/30/02 07:16PM >>> Version 0.7.3 of the gregmisc package
2011 Jul 26
1
Comparing two pdf resulting from density() and identify where significantly smaller or larger?
Hi this might be a little bit off topic, but here it goes: lets assume I have the following: set.seed(13) dat1 <- rnorm(2000, mean=10, sd=10) dat2 <- rnorm(100, mean=10, sd=20) d.all <- density(dat, n=1024) d.co <- density(x[[v]], , from=min(d.all$x), to=max(d.all$x), n=1024) d.diff <- list( x = d.all$x,
2006 Aug 30
2
density() with from, to or cut and comparrison of density()
Hi the function density() does normally integrate to one - I've checked it and it works and I also read the previous threads. But I realised that it does not integrate to one if I use from, to or cut. My scenario: I simulated densities of a plants originating from an sseed source at distance zero. Therefore the density of the plants will be highest close to zero. Is there anything I can do
2005 Oct 26
2
AOV with repeated measures
Dear R user, I have a question on using R to analyze data with repeated measurements. I have 2 species with several strains (12) per species, each of which has been measured twice with for a given trait. No particular covariance, just two measures. Now I want to analyze the data with an ANOVA (aov) considering these repeated measures to get the MSq and SSq for the species and strain level. I
2008 Nov 23
2
Latin Hypercube with condition sum = 1
Hi I want to du a sensitivity analysis using Latin Hypercubes. But my parameters have to fulfill two conditions: 1) ranging from 0 to 1 2) have to sum up to 1 So far I am using the lhs package and am doing the following: library(lhs) ws <- improvedLHS(1000, 7) wsSums <- rowSums(ws) wss <- ws / wsSums but I think I can't do that, as after the normalization > min(wss) [1]
2009 Oct 08
2
intersection of 2 density curves
Hi, I would like to find out the coordinates of the intersection points of 2 density curves. I did a search but i didn't get any significant results. I really hope some of you have some ideas. here it is an example: set.seed(123) x1 <- rnorm(100, 1, 1) x2 <- rnorm(100, 0, 1) d1 <- density(x1) d2 <- density(x2) plot(d1, col = 2) lines(d2, col = 4) Now i would like to know
2007 Oct 24
2
analytical solution to Sum of binominal distributed random numbers?
Frede Aakmann T?gersen wrote: > Perhaps > > http://stinet.dtic.mil/cgi-bin/GetTRDoc?AD=ADA266969&Location=U2&doc=GetTRDoc.pdf > > is something that you can use? Thanks a lot - that might help. Rainer > > > > Best regards > > Frede Aakmann T?gersen > Scientist > > > UNIVERSITY OF AARHUS > Faculty of Agricultural Sciences > Dept.
2009 Jan 29
1
Arima_Like() and NaN - a (possible) problem, a patch, and RFC
Hi, recently I have started working with R (v. 2.7.2), and I have been using R's internal ARIMA_Like() function (from the "stats" package) to estimate some ARIMA models. In particular, I use ARIMA_Like() in a function "fn()" that I feed to the optim() method; the main goal is to find optimal ARIMA prediction models for some time series. The ARIMA_Like() function returns a
2011 Jul 20
0
The C function getQ0 returns a non-positive covariance matrix and causes errors in arima()
Hi, the function makeARIMA(), designed to construct some state space representation of an ARIMA model, uses a C function called getQ0, which can be found at the end of arima.c in R source files (library stats). getQ0 takes two arguments, phi and theta, and returns the covariance matrix of the state prediction error at time zero. The reference for getQ0 (cited by help(arima)) is:
2002 Nov 01
0
Re: gregmisc version 0.7.3 now available
> From: kjetil halvorsen [mailto:kjetilh at umsanet.edu.bo] > > Martin Hoyle wrote: > > > > Dear Greg, > > Thanks for the new release. The decomposition of the SSQ is > just what I need! > > > I thought decomposition of the SSQ can be obtained with the split= > argument to summary.aov? That argument seems tro be new --- it didnt > exist two years
2006 Feb 16
0
SSQ decomposition and contrasts with ANOVA
Dear R list, Please, could someone help me with SSQ decomposition and contrasts. Below my data, graphic, ANOVAs and my doubt: # Data a = paste('a', gl(3, 8), sep='') b = paste('b', gl(2, 4, 24), sep='') tra = sort(paste('t', rep(1:6, 4), sep='')) y = c(26.2, 26.0, 25.0, 25.4, 24.8, 24.6, 26.7, 25.2, 25.7, 26.3, 25.1, 26.4, 19.6,
2006 Feb 14
0
ANOVA: Help with SSQ decomposition and contrasts
# Dear R list, # # A have a doubt about SSQ decomposition and contrasts with ANOVAs. # So, I would like a tip from more advanced R users. # Below my data, the basic script and my doubts: # Data r = paste('r', gl(3, 8), sep='') e = paste('e', rep(gl(2, 4), 3), sep='') tra = sort(paste('t', rep(1:6, 4), sep='')) y = c(26.2, 26.0, 25.0, 25.4,
2006 Sep 20
4
Calculating mean together with split
Hi I have a table called npl containing results of simulations. It contains about 19000 entries and the structure looks like this: NoPlants sim run year DensPlants 1 6 lng_cs99_renosterbos 1 4 0.00192 . . . it has 43 different entries for sim and year goes from 1 to 100, and run from 1 to 5. I would like to calculate the mean of DensPlants for each
2004 Jul 13
0
Calculating sum of squares deviation between 2 similar matrices
Hi all, I've got clusters and would like to match individual records to each cluster based on a sum of squares deviation. For each cluster and individual, I've got 50 variables to use (measured in the same way). Matrix 1 is individuals and is 25000x50. Matrix 2 is the cluster centroids and is 100x50. The same variables are found in each matrix in the same order. I'd like to