similar to: crashing R through lattice

Displaying 20 results from an estimated 600 matches similar to: "crashing R through 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 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, ...) {
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,
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) {
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
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)
2005 Sep 28
1
Problem with memory footprint of qq plot generated with lattice
Dear R helpers, I generate a qq plot using the following function call. qqmath(~val|ind,data=xx ,distribution=function(p) qt(p,df=19) ,ylab="Sample Quatinles" ,xlab="Theoretical Quantiles" ,aspect=1 ,prepanel = prepanel.qqmathline ,panel=function(x,y) { panel.qqmathline(y, distribution=function(p) qt(p,df=19),col=2)
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
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 =
2007 Sep 07
1
tcl/tk help
I am running R 2.5 on a Mac platform and have a difficulty loading the Tcl/Tk package. Specifically: R>library(tcltk) Loading Tcl/Tk interface ... Error in fun(...) : couldn't connect to display ":0" Error : .onLoad failed in 'loadNamespace' for 'tcltk' Error: package/namespace load failed for 'tcltk' Is there an explanation to this problem? Thank you
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
2007 Oct 07
1
Old packages to updated R
I am 100% positive there is a better fix for this problem and it has been discussed. Thank you in advance for bringing it to my attention. When upgrading to newer versions of R the old packages are not brought along in the process. I solved that problem by creating a list of the packages in the old version of R, importing them to the new version via a CSV, and re-installing into the newer R
2008 Jun 10
3
fitting periodic 'sine wave' model
I have been attempting to estimate the periodic contribution of an effect to some data but have not been able to fit a sine wave within R. It would be nice to start by being able to fit a sine wave with an amplitude and frequency. x<-seq(0,20,by=0.5) y<-2*sin(2*pi*.5*x) #amplitude =2, frequency=0.5 # This failed to converge r<-nls(y ~ A*sin(2*pi*F*x), start=list(A = 1, F = 1),
2009 Sep 16
3
apply function across two variables by mult factors
Greetings, I am attempting to run a function, which produces a vector and requires two input variables, across two nested factor levels. I can do this using by(X, list(factor1, factor2), function), however I haven't found a simple way to extract the list output into an organized vector form. I can do this using nested loops but it isn't exactly an optimal approach. Thank you
2009 Jun 12
2
Automate a data load and merge
Hi R list, I would like to automate, or speed up the process from which I take several separate datasets, stored in .csv formate, import and merge them by a common variable. So far I have greatly sped up the loading process but cannot think of a way to automate the merger of all datasets into a common data.frame. My apologies if this has been covered, any R search suggestions are
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
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
2008 Apr 11
1
polygons on scatterplot3d
Does anyone have any experience plotting complex polygons on a scatterplot3d display? I would like to present some spatially binned data in a 3-d type plot with background polygons (i.e.. a filled coastline map). I can get the coastline onto the plot window as a line type but cannot figure out how to fill the shape. I'm certain it may be possible but might require a bit of digging
2008 Mar 15
1
Conditionals for Errors or error flags
Greetings, I have been working on a script that conducts repeated statistics and plots to my data. In this case it is sub-setting the dataframe by month. The intent is to develop a custom analysis and plotting that I can run on a large number of data sets. Unfortunately, a small portion of my subsets (~1%) cause an error with one of the wrapped subroutines that results in the whole