similar to: checking bivariate normality

Displaying 20 results from an estimated 2000 matches similar to: "checking bivariate normality"

2010 Sep 30
3
how to avoid NaN in optim()
hi , lik <- function(nO, nA, nB, nAB){ loglik <- function(par) { p=par[1] q=par[2] r <- 1 - p - q if (c(p,q,r) > rep(0,3) && c(p,q,r) < rep(1,3) ) { -(2 * nO * log (r) + nA * log (p^2 + 2 * p * r) + nB * log (q^2 + 2 * q * r) + nAB * (log(2) +log(p) +log(q))) } else NA } loglik }
2010 Apr 08
1
square root of inverse
Dear users, How to get a symmetric square root of a positive definite matrix? I have tried using spectral decomposition, but some eigen values come out to be complex. Is there any function in R that can give the symmetric square root of a pd matrix? -- Arindam Fadikar M.Stat Indian Statistical Institute. New Delhi, India [[alternative HTML version deleted]]
2011 Jan 30
1
how to enter frequency type data in R with class intervals
Dear all, Given data of a continuous frequency distribution with class intervals .. how to enter such data so that we can use the normal mean, median and mode functions to calculate them and also can draw histogram .. for example how to enter this data in R Height range[image: ↓]<http://en.wikipedia.org/wiki/Frequency_distribution#> Number of students[image: ↓]
2007 Aug 30
2
Need help putting histograms on the diagonal of a splom plot
Hello, I am in need of help in putting histograms on the diagonal of a plot produced with splom(). The plot matrix I am trying to produce is to have standard scatterplots in the upper-left triangle, contour plots in the lower-right triangle, and histograms on the diagonal. I have a function that does the first two, but the histograms on the diagonal has been beyond my ability. Here is my
2002 Dec 09
1
3D density estimation
I am trying to carry out density estimation for three dimensions (with anywhere between a few hundred and ~8000 data points). Which leads me to ask: a) is there any equivalent to kde2d (in MASS) or bkde2D (in KernSmooth) out there for three dimensions? b) if not, my skills only seem to extend as far as writing a function which measures density as the number of data points falling within a
2006 Apr 23
3
bivariate weighted kernel density estimator
Is there code for bivariate kernel density estimation? For bivariate kernels there is kde2d in MASS kde2d.g in GRASS KernSur in GenKern (list probably incomplete) but none of them seems to accept a weight parameter (like density does since R 2.2.0) -- Erich Neuwirth, University of Vienna Faculty of Computer Science Computer Supported Didactics Working Group Visit our SunSITE at
2003 Oct 22
1
2 D non-parametric density estimation
I have spatial data in 2 dimensions - say (x,y). The correlation between x and y is fairly substantial. My goal is to use a non-parametric approach to estimate the multivariate density describing the spatial locations. Ultimately, I would like to use this estimated density to determine the area associated with a 95% probability contour for the data. Given the strong correlation between x and
2005 Mar 21
1
Convert numeric to class
Dear all, I have a script about iteration classification, like this below data(iris) N <- 5 ir.tr.iter <- vector('list',N) ir.tr <- vector('list',N) for (j in 1:N) { ir.tr[[j]] <- rpart(Species ~., data=iris) ir.tr.iter[j] <- ir.tr[[j]]$frame result <- list(ir.tr=ir.tr, ir.tr.iter=ir.tr.iter) } as.data.frame(as.matrix(ir.tr.iter))
2000 Jun 20
1
density estimation in two dimensions
Hello, I am a newbie to R and the subject of density estimation in two dimensions or more. I would like to have some advice concerning a comparison between the R packages for density estimation in bivariate or higher order problems; I mean explicitly the packages: 1) ash 2) KernSmooth 3) locfit 4) sm. My specific problem now is having a set of numerical pairs (x_i, y_i), arising from a
2008 Jan 16
1
Probability weights with density estimation
I am a physician examining an NHANES dataset available at the NCHS website: http://www.cdc.gov/nchs/about/major/nhanes/nhanes2005-2006/demo_d.xpt http://www.cdc.gov/nchs/about/major/nhanes/nhanes2005-2006/hdl_d.xpt http://www.cdc.gov/nchs/about/major/nhanes/nhanes2005-2006/tchol_d.xpt Thank you to the R authors and the foreign package authors in particular. Importing from the SAS export
2006 May 31
2
a problem 'cor' function
Hi list, One of my co-workers found this problem with 'cor' in his code and I confirm it too (see below). He's using R 2.2.1 under Win 2K and I'm using R 2.3.0 under Win XP. =========================================== > R.Version() $platform [1] "i386-pc-mingw32" $arch [1] "i386" $os [1] "mingw32" $system [1] "i386, mingw32" $status
2012 Jun 11
1
saving sublist lda object with save.image()
Greetings R experts, I'm having some difficulty recovering lda objects that I've saved within sublists using the save.image() function. I am running a script that exports a variety of different information as a list, included within that list is an lda object. I then take that list and create a list of that with all the different replications I've run. Unfortunately I've been
2012 May 03
1
Identifying case by groups in a data frame
Hi everyone, I would like to identify the case by groups that is just bigger that avg plus sd. For example, using species as group and petal.wid as my variable in the iris data. What's the better way to doit? creating a function? So,the question is to identify the single element of each species that is just larger than a cut-off point (i.e. larger than mean + sd) I made this, but I can not
2012 Jul 31
1
kernlab kpca predict
Hi! The kernlab function kpca() mentions that new observations can be transformed by using predict. Theres also an example in the documentation, but as you can see i am getting an error there (As i do with my own data). I'm not sure whats wrong at the moment. I haven't any predict functions written by myself in the workspace either. I've tested it with using the matrix version and the
2008 Oct 13
2
split data, but ensure each level of the factor is represented
Hello, I'll use part of the iris dataset for an example of what I want to do. > data(iris) > iris<-iris[1:10,1:4] > iris Sepal.Length Sepal.Width Petal.Length Petal.Width 1 5.1 3.5 1.4 0.2 2 4.9 3.0 1.4 0.2 3 4.7 3.2 1.3 0.2 4 4.6 3.1 1.5
2011 Jul 28
2
not working yet: Re: lattice overlay
Hi Dieter and R community: I tried both of these three versions with ylim as suggested, none work: I am getting only single (pch = 16) not overlayed (pch =3) everytime. *vs 1* require(lattice) xyplot(Sepal.Length ~ Sepal.Width | Species , data= iris, panel= function(x, y, subscripts) { panel.xyplot(x, y, pch=16, col = "green4", ylim = c(0, 10)) panel.lmline(x, y, lty=4, col =
2009 Oct 17
1
Easy way to `iris[,-"Petal.Length"]' subsetting?
Dear all What is the easy way to drop a variable by using its name (and not its number)? Example: > data(iris) > head(iris) Sepal.Length Sepal.Width Petal.Length Petal.Width Species 1 5.1 3.5 1.4 0.2 setosa 2 4.9 3.0 1.4 0.2 setosa 3 4.7 3.2 1.3 0.2 setosa 4 4.6 3.1
2008 Feb 27
2
multiple plots per page using hist and pdf
Hello, I am puzzled by the behavior of hist() when generating multiple plots per page on the pdf device. In the following example two pdf files are generated. The first results in 4 plots on one pdf page as expected. However, the second, which swaps one of the plot() calls for hist(), results in a 4 page pdf with one plot per page. How might I get the histogram with 3 other scatter
2012 Jul 23
1
duplicated() variation that goes both ways to capture all duplicates
Dear all The trouble with the current duplicated() function in is that it can report duplicates while searching fromFirst _or_ fromLast, but not both ways. Often users will want to identify and extract all the copies of the item that has duplicates, not only the duplicates themselves. To take the example from the man page: > data(iris) > iris[duplicated(iris), ] ##duplicates while
2011 Jul 30
1
grImport symbols
Dear list, I have two questions regarding grid.symbols() in the grImport package. This package allows you to import a vector graphic in R, and grid.symbols() can be used to plot the resulting glyph at arbitrary locations in a grid viewport. I have tried the code in the grImport vignette, which is most interesting, however I am stuck with two problems: 1- Is there a possibility to create a