Displaying 20 results from an estimated 900 matches similar to: "Problem with memory footprint of qq plot generated with lattice"
2012 May 17
3
New Eyes Needed to See Syntax Error
One of many scripts to produce 4 lattice plots on one page keeps throwing
an error. I've tried manipulating the file to eliminate the error, but have
not been able to do so. The error is:
> source('bicarb.R')
Error in source("bicarb.R") : bicarb.R:15:1: unexpected symbol
14: 15: hco33
^
The 'h' is in column 0 so the caret would be column -1, but it's
2006 May 25
2
qqmath - Lattice error
Hi,
Don't have a clue what teh following error message
generated by this function call:
qqmath( ~val|ind,data = xx
,distribution = function(p){ qt(p,df=20)}
,ylab="Sample Quatinles"
,xlab="Theoretical Quantiles"
,panel=function(x,y)
{
panel.qqmathline(y
, distribution=function(p) qt(p,df=20)
2006 Oct 11
1
panel-dependent distribution in qqmath
In qqmath, how would one go about having 'distribution' change with
panel.number? I've tried
set.seed(1)
mydata <- data.frame(ind = factor(rep(2:4, each = 100)))
mydata$val <- rt(300, df=rep(2:4, each = 100))
plot<-qqmath(~ val | ind,
layout=c(3,1),
data = mydata,
prepanel = function(x, distribution, ...) {
2008 Aug 28
1
error in packet 1
Hello,
I'm Giovanni from ROMA..
I can't find a solution for the error:
"error using packet 1
the y field is not specified and it has not a default value"
(this is my traslation from italian language)
The code is:
pc<- qqmath(~valori,
distribution=function(p) qweibull(p,beta,alpha),
prepanel = prepanel.qqmathline,
panel = function(x, y) {
2008 Aug 28
1
"error using packet 1"
Hello,
I'm Giovanni from ROMA..
I can't find a solution for the error:
"error using packet 1
the y field is not specified and it has not a default value"
(this is my traslation from italian language)
The code is:
pc<- qqmath(~valori,
distribution=function(p) qweibull(p,beta,alpha),
prepanel = prepanel.qqmathline,
panel = function(x, y) {
2007 Sep 27
1
crashing R through lattice
I have been crashing R while using lattice. My system consists of a Mac
Intel, R 2.5.1, lattice 0.15-5, and I plot through the default quartz.
R crashes after plotting several lattice functions. Has anyone else
encountered this problem and does anyone know the cause, or a solution?
Is this a lattice:mac, lattice:quartz, Lattice:me issue?
example...
This crashes my system after plotting.
2013 Jun 22
1
Superpose two QQ-plots (gamma distribution) with, lattice function qqmath()
David, Duncan,
> Hi
>
> Following on David's rate argument
>
> try (with modifications of pch and grid)
>
> rate <- 1/4
> shape = 8
> rate = c(rep(1/4,100),rep(1/3,100))
I don't think the problem is related to the rate argument, which can
well be vectorized, as is the case for a number of arguments in distrib
functions in R (note that you are redefining it
2011 Feb 04
0
switching y-axis to x-axis for qqmath
This is the qqmath example from the lattice package. I added the scales to the example. I would like to switch the axis and not sure how? Meaning I would like the "height" on the x-axis and the probability on the y-axis. Will you show me the correct syntax for this switch thanks.
qqmath(~ height | voice.part, aspect = "xy", data = singer,
prepanel =
2003 Oct 04
1
How to use panel.qqmathline?
Dear R users:
How can I use panel.qqmathline, in package lattice, to add
straight lines onto the plots generated by qqmath?
I read help pages of qqmath, panel.qqmathline, xyplot, ...,
but just can't one example that shows how to make it work.
For example,
> data(sleep)
> qqnorm(~ extra | group, data=sleep, aspect=1)
how can I use panel.qqmathline?
Thanks very much for your help,
2007 Jan 23
1
How to generate 'minor' ticks in lattice (qqmath)
Dear group,
I tried to generate labels for every second tick in lattice (qqmath).
Version: 0.14-16
Date: 2006/12/01
R version 2.4.1 (2006-12-18)
An example:
library(lattice)
numy=100
y=runif(numy,min=0,max=1)
sig=0.05
numsig=length(which(y<sig))
tck.no=11 # number of ticks
tcks=1:tck.no
labl=as.character(0.1*tcks-0.1) # label for all ticks
labl[seq(2,tck.no-1,2)]="" # delete
2007 Feb 09
1
How to add the variable name to a qqplot or densityplot in the diagonal of an splom?
splom() doesn't complain here, but writes no names in the diagonal
boxes. What am I missing?
I believe that I need to add something like grid.text(x, ...) to the
diagonal panel, but I don't know how to get it cycle through the
column labels. And should
varname.col = 'blue', varname.cex = 1
be inside the diag.panel() function?
splom(szw[, n], pscales = 0,
diag.panel
1999 Aug 31
1
Suggestion for qqplot() improvement
>>>>> On Tue, 31 Aug 1999 14:57, Werner Stahel <stahel@stat.math.ethz.ch> said:
WSt> Here is a suggestion. It seems that qqplots, comparing a sample
WSt> to a distribution other than the normal, are not explicitly
WSt> available in S or R. I found
(in S-plus / Trellis it is, see below)
WSt> qqplot(y, rt(300, df = 5))
WSt> as an
2009 Dec 28
1
Help With Custom QQ Plot
Good Morning:
I have attached a text file with one hundred thirty six observations. I would like to create a qq plot with the following features:
1. Observed values on the y-axis.
2. Normal approximation line on the plot.
3. X-axis with vertical reference lines at the following percentiles of the data: 1, 10, 20, 50, 80, 90 and 99.
4. Data appearing on the plot as distinct points.
I assume that
2009 May 27
1
Changing point color/character in qqmath
Having solved this problem, I am posting this so that the next time I search
for how to do this I will find an answer...
Using qqmath(..., groups=num) creates a separate qq distribution for each
group (within a panel). Using the 'col' or 'pch' argument does not
(usually) work because panel.qqmath sorts the data (but not 'col' or 'pch')
before plotting. Sorting
2012 May 15
1
Lattice: Add abline to Single Value qqmath() Plot
The data are not normally distributed when untransformed and I'm trying
various transformations to see if any would be appropriate to use. The
lattice book (fig. 3.10) shows a 2-sample Q-Q plot with an abline but the
code for the figure does not include the line.
I'd appreciate a pointer to a reference on how to add an abline to a
one-sample qqmath() plot in lattice.
Rich
2009 Sep 17
2
QQ plotting of various distributions...
Hello!
I am trying with this question again:
I would like to test few distributional assumptions for some behavioral
response data. There are few theories about true distribution of those
data, like: normal, lognormal, gamma, ex-Gaussian
(exponential-Gaussian), Wald (inverse Gaussian) etc. The best way would
be via qq-plot, to show to students differences. First two are trivial:
qqnorm(dat$X)
2009 Feb 08
2
how to make this qq plot in lattice and/or ggplot2
Hi Group,
Here is some data.
p <- runif(1000) # sample data
groups <- rep(c(1,2),each=500) #conditioning variable
mydata <- cbind(p,groups)
n <- length(p)
u <- (1:n)/(n + 1) # uniform distribution reference for qqplot
logp <- -log(p,base=10)
logu <- -log(u,base=10)
qqplot(logp,logu)
How can I make the above qqplot in lattice and/or ggplot2. The sample
is uniform, and I take
2001 Nov 29
2
text in qqmath
Hello,
I can't seem to make qqmath plot text.
v <- rnorm(8)
qqmath(~v) # this is ok, but
qqmath(~v, panel=function(x, y) {
points(x, y)
text(0, 0, 'print me', cex=2)})
isn't ok.
The axis frame is printed properly (ie, as in
qqmath(~v)), but neither 'print me' nor the points
show up on the graph. I can, however, see the upper
half of the word 'me' in the
2005 Aug 04
4
optim
Dear R-helpers,
The function optim implements algorithms that I would like to use.
I have function implemented in R, which given the parameters of which
minimization is to take place returns a scalar as well as the gradient.
Unfortunately optim requires two function _fn_ and _gr_ where fn returns the
function value and gr the gradient. Splitting my function in two functions
would be easy,
2005 Sep 13
3
NUMERIC_POINTER question
Dear R-developers,
Using .Call I pass a S4 class with e.g. the following class definition:
setClass("mmatrix",representation(
data="matrix")
)
On the "C side" i do
mat = GET_SLOT(vs,install("data"));
and then:
printf("%f\n",NUMERIC_POINTER(mat)[1]);
The above print statement produces the correct output if
xx<- new("mmatrix")