Displaying 20 results from an estimated 4000 matches similar to: "Measuring the effects of history on event probabilities"
2006 Nov 06
7
Colour-coded Editor for R Code
Do any of you know any simple programming editors for R scripts which offer
basic colour-coding and bracket-matching facilities?
Dregging through scripts to find a missing comma or parentheses is something
I'd rather do less of...
Jon Minton
[[alternative HTML version deleted]]
2006 Oct 31
2
R crashing during batch file formatting
Hi R users:
I have the British Household Panel Survey (BHPS) in .tab format. I want to
feed it through the Amelia package (which will be an ‘interesting’ job in
itself)..
But first I need to convert the various types of missing value (from about
-9 to -1) to a more generic ‘NA’ code.
I’ve written the following function to do this:
BHPS.converter <-
2006 Aug 28
2
regex scares me
Hi, apologies if this is too simple but I've been stuck on the following for
a while:
I have a vector of strings: filenames with a name before the extension and a
variety of possible extensions
I want to select only those files with:
1) a ".tab" extension
AND
2) the character sequence "lad" anywhere in the name of the file before the
extension.
Surely this
2006 Sep 13
7
inserting columns in the middle of a dataframe
Dear R users:
Is there a built-in and simple way to insert new columns after other columns
in a dataframe?
I.e. currently I have:
V1 V2 V3 V4
[1,]
[2,]
Etc.
But I want
V1 V5 V2 V3 V4
[1,]
[2,]
Etc.
Can this be done in one line?
Jon Minton
[[alternative HTML version deleted]]
2006 Nov 04
2
Equivalent to Stata command
Hi:
Do any of you know if there's an equivalent function to the Stata command:
Use v1 v3 v5 v2 v7 using file.dat
In R? (i.e. something that just selectively loads certain variables from a
file and not others)?
Thanks
Jon Minton
[[alternative HTML version deleted]]
2007 Apr 23
1
automating merging operations from multiple dataframes
Hi,
I have a set of dataframes names AINDSLIM, BINDSLIM, CINDSLIM ... NINDSLIM
In each dataframe I want to extract two variables, “pid” and “{w}region”,
where {w} means “a”, “b”, “c”, ...”n”
At the moment my code looks like:
> PidRegion <- data.frame(pid=XWAVEID$pid)
> this.region <- AINDSLIM[,c("pid", "aregion")]
> PidRegion <- merge(PidRegion,
2011 Nov 21
1
Sensitivity and Specificity Forest Plots
Dear R Users,
Do you know of an existing function that allows the production of
sensitivity and specificity forest plots?
See the following for an example:
2012 Dec 06
1
Anomalous outputs from rbeta when using two different random number seeds
Hi, in the code below, I am drawing 1000 samples from two beta
distributions, each time using the same random number seed.
Using set.seed(80) produces results I expect, in that the differences
between the distributions are very small.
Using set.seed(20) produces results I can't make sense of. Around half of
the time, it behaves as with set.seed(80), but around half of the time, it
behaves
2009 Jun 23
1
nested cross-sectional design using lmer or nlme
Dear all, I'd appreciate some advice on the following problem. I'm
attempting to analyse a nested cross-sectional design in which an
intervention was offered to a series of randomly selected (small)
communities, so the unit of randomisation is the community. All
available individuals in each community were interviewed before the
intervention and again at follow-up
2019 Feb 28
3
What files to edit when changing the sdX of hard drives?
Phelps, Matthew wrote:
> On Thu, Feb 28, 2019 at 11:52 AM mark <m.roth at 5-cent.us> wrote:
>> Nicolas Kovacs wrote:
>>> Le 28/02/2019 ? 04:12, Jobst Schmalenbach a ?crit :
>>>> I want to lock in the SDA/SDB/SDC for my drives
>>>
>>> In short : use UUIDs or labels instead of hardcoding /dev/sdX.
>>>
>>>
2007 Sep 22
1
reshape() to wide with varying number of responses to fields
Hello,
I have a dataframe containing the following variables:
PID, Field, Value
Where PID refers to a unique individual, Field to a particular question, and
Value to a particular response to a question.
I?d like this in wide format, with a different row for each PID.
However.... there are differing numbers of Values associated with each
Field, for each PID.
For example, a Field question may
2008 Oct 18
2
sorting matrix output alphabetically
Hello,
I have been using the TM package to create a TermDocMatrix, which I
have saved as a matrix so that I can view word frequencies. Below is
a section of the code that I have used and an excerpt of the output:
What I wanted to be able to do is to view the output alphabetically -
rather than the results being sorted by frequency as below, that an
alphabetical list would be generated. This
2004 Nov 04
4
highly biased PCA data?
Hello, supposing that I have two or three clear categories for my data,
lets say pet preferece across fish, cat, dog. Lets say most people rate
their preference as being mostly one of the categories.
I want to do pca on the data to see three 'groups' of people, one group
for fish, one for cat and one for dog. I would like to see the odd person
who likes both or all three in the
2007 Sep 07
1
R survey package again
Hi R-users!!
I have some trouble with the survey pakage and i would be very glad if you can give me an advice.
I have a sample from a survey where household were interviewed. The sample has 4 criteria on which the stratification was based: REGION, SIZE OF HOUSEHOLD, SIZE OF LOCALITY, AGE OF HEAD OF HOUSEHOLD. Since i don't have the whole information in each cell of the cross
2013 Feb 18
2
How to label percentage values inside stacked bar plot using R-base
Hello, I am new to R. I would like others to explain to me how to add
absolute values inside the individual stacked bars in a consistent way
using the basic R plotting function (R base). I tried to plot a stacked bar
graph using R base but the values appear in an inconsistent/illogical way
in such a way that its supposed to be 100% for each village but they don't
sum up to 100%.
Here is the
2004 Oct 01
3
Plotting panels at arbitrary places on a map, rather than on a lattice
I think it is easiest to describe
what I want in terms of the concrete
problem I have.
I have data from a number of countries
in each of which a sample of people was
interviewed. In presenting the results
in a forthcoming collaborative publication
much emphasis will be placed on the
multi-centre nature of the study. Although
I suspect colleagues may do this with
shaded maps I would prefer to
2009 Oct 14
1
Announcement: New R book--50% off today only
Hi all,
This is Steven with Manning Publications. I wanted to announce the
launch of a new R book: R in Action by Rob Kabacoff. Rob was recently
interviewed for this piece on Teradata about the growth of R into new
fields and the future of R. The book gives thorough coverage of the R
environment with dozens of practical examples of its uses.
We're doing a one day 50% off deal on the
2010 May 10
6
AEC - Echo is cancelled however.....
1) Everytime a participant speaks there is a echo for a short duration
(maybe a word or two) but as the participant continues to speak without a
any break the echo is 95% cancelled (i.e there is a feeble echo still
present if observed very carefully).
2) The moment the participant stops / pauses speaking and start talking
again, scenario 1 is repeated as if the echo state has been re-initialized
2007 Feb 16
2
missing -> nonmissing levels
Hi,
I expect this is simple but haven’t found an answer looking on the
archives...
I want to convert ‘NA’ (missing) to particular levels (nonmissing) in factor
vectors.
e.g. I know
> X <- c(1, 2, 3)
> summary(X)
Min. 1st Qu. Median Mean 3rd Qu. Max.
1.0 1.5 2.0 2.0 2.5 3.0
> X <- as.factor(X)
> summary(X)
1 2 3
1 1 1
>
2010 Sep 08
4
Interpreting logwatch
Every few days I see in the logwatch on my Centos-5.5 web-server
what seems like a rather feeble break-in attempt.
Eg today I see
---------------------------
403 Forbidden
/phpMyAdmin/scripts/setup.php: 2 Time(s)
/phpmyadmin/scripts/setup.php: 2 Time(s)
404 Not Found
/PMA2005/scripts/setup.php: 1 Time(s)
/TRAD_files/datestamp.js: 1 Time(s)
...