similar to: fisher.test gives p>1

Displaying 20 results from an estimated 6000 matches similar to: "fisher.test gives p>1"

2010 Feb 04
4
xyplot 3 panels 3 different Y variables
Often, when exploring a dataset, I'd like to plot several very different Y variables against the same X variable, in panels stacked one over the other. Is there an easy way to do this? I'd like to achieve an elegant look similar to the look achieved by lattice in conditioned plots--for instance no space between panels. But unlike in straightforward conditioned plot, each panel may be on a
2009 Oct 28
3
variable labels to accompany data.frame
Often it is useful to keep a "codebook" to document the contents of a dataset. (By "dataset" I mean a rectangular structure such as a dataframe.) The codebook has as many rows as the dataset has columns (variables, fields). The columns (fields) of the codebook may include: ? variable name ? type (character, factor, integer, etc) ? variable label
2010 Jun 18
1
ggplot2 boxplot: horizontal, univariate
In ggplot2, I would like to make a boxplot that has the following properties: (1) Contrary to default, the meaningful axis should be the horizontal axis. Lattice does this, for instance, by library(lattice);bwplot(~mtcars$mpg) (2) It is *univariate*, i.e., of a single vector, say mtcars$mpg. I do not wish to make separate plots for the different values of mtcars$cyl. (3) Nothing on the
2009 Oct 12
3
xyplot does not find variable in data
When we call a lattice function such as xyplot, to what extent does the "data" designation cause the function to look inside the "data" for variables? In the examples below, the "subset" argument understands that "Variety" is a variable in the data. But the "scales" argument does not understand that "nitro" is a variable in the data.
2009 Jul 26
1
obtain names of variables and data from glm object
Suppose we have some glm object such as: myglm <- glm( y ~ x, data=DAT) Is there an elegant way--or the "right way" within the R way of thinking--to obtain the names of the response variable, the predictor variables, and the dataset, as character strings? For instance, suppose the "right way" was to use the (currently fictitious) functions theresponse(), thepredictors(),
2009 Aug 03
3
session logging
Consider all the text that one sees on the console during an R session. Is there a way, within R, to make all this text--both the "output" and the "messages"--automatically get copied to a single text file, in addition to seeing it on the console? If I remember to save the console to a file at the end of my R session, that does it. But (1) That requires pointing and
2009 Oct 10
1
lattice auto.key drop unused levels
The following code produces a legend ("key") that mentions the unused levels of Block. library(MEMSS) xyplot(yield~nitro, subset=(Block=="I" | Block=="II"), data=Oats, group=Block, auto.key=T) and adding "drop.unused.levels=T" does not fix it. And in fact even the following does not solve the problem: xyplot(yield~nitro,
2009 Nov 11
1
loop through variable names
Often I perform the same task on a series of variables in a dataframe, by looping through a character vector that holds the names and using paste(), eval(), and parse() inside the loop. For instance: thesevars<-names(environmental) environmental$ToyOutcome<-rnorm(nrow(environmental)) tableOfResults<-data.frame(var=thesevars) tableOfResults$Beta<- NA
2008 Jul 17
2
nested calls, variable scope
Below is an example of a problem I encounter repeatedly when I write functions. A call works at the command line, but it does not work inside a function, even when I have made sure that all required variables are available within the function. The only way I know to solve it is to make the required variable global, which of course is dangerous. What is the elegant or appropriate way to solve
2010 Feb 07
2
conditioned xyplot, many y variables
The example below creates parallel time-series plots of three different y variables conditioned by a dichotomous factor. In the graphical layout, ? Each y variable inhabits its own row and is plotted on its own distinct scale. ? Each level of the factor has its own column, but within each row the scale is held constant across columns. ? The panels fit tightly (as they do
2009 Aug 05
4
multiple lty on same panel in xyplot
I would like to use lattice graphics to plot multiple functions (or groups or subpopulations) on the same plot region, using different line types "lty" or colors "col" to distinguish the functions (or groups). In traditional graphics, this seems straightforward: First plot all the data using 'type="n"', and subsequently execute a series of "points"
2009 Aug 06
1
specify lattice black-and-white theme
Is there a simple way to specify a theme or trellis (lattice) parameters so that, in a multipanel (conditioned) plot, there is no color and in the strips there is no shading? This is the effect achieved on page 124 of Deepayan Sarkar's "Lattice" (figure 7.2). I managed to trick lattice into making a grayscale plot on my interactive display as follows: > graphics.off() >
2013 Dec 02
2
plus/minus +/- in factor; not plotmath not expression
I want to put the "plus or minus" symbol into a character variable, so that this can be turned into a factor and be displayed in the "strip" of a faceted ggplot2 plot. A very nice solution, thanks to Professor Ripley's post of Nov 16, 2008; 3:13pm, visible at http://r.789695.n4.nabble.com/Symbols-to-use-in-text-td874239.html and subsequently
2011 Nov 10
1
unable to load Hmisc in R 2.14.0
On my MacBook Pro (OS 10.6.8), after updating to R version 2.14.0 (2011-10-31) and reinstalling the Hmisc package, I am unable to load the Hmisc library. Hmisc was working *before* I updated R. Any idea what's wrong? Details below. > install.packages("Hmisc", dependencies=TRUE) trying URL 'http://cran.case.edu/bin/macosx/leopard/contrib/2.14/Hmisc_3.9-0.tgz' Content
2009 Aug 07
1
lattice: simultaneously control aspect & outer whitespace
Suppose we wish to achieve the following three aims: (1) Control the aspect ratio of our plot (i.e., tweak this till it looks great) (2) Save the plot as a PDF with zero or minimal white space outside it. (3) Preserve this in code, so that in the future the exact same plot can be reproduced by simply sourcing the code. I can almost achieve (1) and (2) on my MacBook Pro by pointing and clicking,
2012 Dec 06
1
scope, lme, ns, nlme, splines
I want to fit a series of lme() regression models that differ only in the degrees of freedom of a ns() spline. I want to use a wrapper function to do this. The models will be of the form y ~ ns(x, df=splineDF) where splineDF is passed as an argument to a wrapper function. This works fine if the regression function is lm(). But with lme(), I get an error. fitfunction() below demonstrates this.
2007 Oct 05
3
Mac GUI and .Renviron
The .Renviron and .First functions do not seem to work the same way on a Mac OS 10.4 as on a Windows XP machine. From working in Windows I am used to creating a new directory for each data analysis project. In the new directory I place First, an .Renviron file consisting of the following text: R_HISTFILE="history.txt" R_HISTSIZE=1000000 Second, an .RData file containing a .First
2001 Sep 10
1
Help with exporting keys
Hi, In our department's setup we have a unfortunate situation where we have to use both OpenSSH and SSH (ssh.com's version). I have managed to export keys from OpenSSH to SSH's format. I also managed to export SSH's public key to OpenSSH's format. Now I would like to add the private key of SSH to the agent. Now when I try to add it simply by using ssh-add
2014 Sep 12
3
ntpd in VM
I was taught in kitty school that running a ntp server in a vm was a bad idea. Is that still the case?
2005 Jun 03
3
p-value > 1 in fisher.test()
The following contingency table generates p-value > 1 from fisher.test() ff = c(0,10,250,5000); dim(ff) = c(2,2); fhisher.test(ff)$p.value Sean [[alternative HTML version deleted]]