I did not care to load the packages -- small reproducible examples are
preferable, as the posting guide suggests.
But, if I have understood correctly:
See, e.g. ?subset
Alternatively, you can read up on indexing data frames in any good basic R
tutorial.
Cheers,
Bert
Bert Gunter
"The trouble w
Dear All:
I would like to create a subset data set *with only* all Ford and all
Toyota cars from the Auto data set in ISLR R Package. Thank you very much
in advance.
Please use the following code to see how is the data look like.
install.packages("ISLR")
library(ISLR)
data(Auto)
head(Auto)
On Sat, 16 Dec 2017, Erin Hodgess writes:
> Hello everyone!
>
> I'm in the process of writing a package, and I'm using the lovely "R
> Package" book as a guideline.
>
> However, in the midst of my work, I discovered that I had omitted a
> function and am now putting in it the package. Not a prob
On 16/12/2017 10:15 AM, Berwin A Turlach wrote:
G'day Erin,
On Sat, 16 Dec 2017 08:00:38 -0600
Erin Hodgess wrote:
I'm in the process of writing a package, and I'm using the lovely "R
Package" book as a guideline.
However, in the midst of my work, I discovered that I had omitted a
function
G'day Erin,
On Sat, 16 Dec 2017 08:00:38 -0600
Erin Hodgess wrote:
> I'm in the process of writing a package, and I'm using the lovely "R
> Package" book as a guideline.
>
> However, in the midst of my work, I discovered that I had omitted a
> function and am now putting in it the package. No
Slightly faster: sum(cumsum(hyd) <= .5 * sum(hyd))
Best regards,
ir. Thierry Onkelinx
Statisticus / Statistician
Vlaamse Overheid / Government of Flanders
INSTITUUT VOOR NATUUR- EN BOSONDERZOEK / RESEARCH INSTITUTE FOR NATURE
AND FOREST
Team Biometrie & Kwaliteitszorg / Team Biometrics & Quality
... and please note for the future and in case Ben's reply does not suffice
that such queries should generally go to the r-package-devel mailing list.
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along and
sticking things into it."
-- Opus (aka Ber
Hi,
If you are using roxygen-style function documentation then why not use
devtools::document()?
Ben
> On Dec 16, 2017, at 9:00 AM, Erin Hodgess wrote:
>
> Hello everyone!
>
> I'm in the process of writing a package, and I'm using the lovely "R
> Package" book as a guideline.
>
> Howe
Hello everyone!
I'm in the process of writing a package, and I'm using the lovely "R
Package" book as a guideline.
However, in the midst of my work, I discovered that I had omitted a
function and am now putting in it the package. Not a problem. But the
problem is the help file. What is the be
Hi Eric,
How about
match( TRUE, cumsum(hyd/sum(hyd)) > .5 ) - 1
HTH,
Eric
On Sat, Dec 16, 2017 at 3:18 PM, Morway, Eric wrote:
> The small bit of script below is an example of what I'm attempting to do -
> find the day on which the 'center of mass' occurs. In case that is the
> wrong term, I
The small bit of script below is an example of what I'm attempting to do -
find the day on which the 'center of mass' occurs. In case that is the
wrong term, I'd like to know the day that essentially cuts the area under
the curve in to two equal parts:
set.seed(4004)
Date <- seq(as.Date('2000-09-
11 matches
Mail list logo