Hello!
I have following data and I am trying to apply bootstrapping. My data and code
is as follows-
amounts =
c(829.53,4000,6000,1000,1063904,102400,22000,4000,4200,2000,1,400,459006,7276,4000,100,4000,1,613803.36,
3825,1000,5000,4000,3000,84500,200,2000,68000,97400,6267.8,49500,2700
Hi All,
I have quite a few files which is having HTML tabular data. All the files have
have different format, numerous nested tables and different information and the
table structure is completely different. The only common thing in these files
is that they are in tables.
I was able to read th
dplyr solution:
bevs %>% group_by(name, sex, drink) %>% summarise(cost = sum(cost)) %>%
select(name, drink, cost, sex)
The last select statement puts the output in the column order you wanted in
your result.
I hope this helps.
Brian
On Wed, Jul 29, 2015 at 9:37 PM, Jon BR wrote:
> Hello,
David,
I do appreciate your help, if not the dose of contempt. I hope you
feel OK.
Thanks for the tips,
-Jonathan
On Wed, Jul 29, 2015 at 11:14 PM, David Winsemius
wrote:
>
> On Jul 29, 2015, at 7:37 PM, Jon BR wrote:
>
> > Hello,
> >I've recently discovered the helpful dplyr package.
On Jul 29, 2015, at 7:37 PM, Jon BR wrote:
> Hello,
>I've recently discovered the helpful dplyr package. I'm using the
> 'aggregate' function as such:
The `aggregate` function is part of base-R:
> bevs <- data.frame(cbind(name = c("Bill", "Mary"), drink = c("coffee",
> "tea", "cocoa", "wa
Hi Brian,
Thanks for the suggestion, although the command is throwing an error as
such:
> bevs %>% group_by(name, sex, drink) %>% summarise( cost = sum(cost)) %>%
select(name, drink, cost, sex)
Error: unexpected input in "bevs %>% group_by(name, sex, drink) %>%
summarise( "
Your syntax is new
Hi All,
I am writing a Vignette with Knitr using devtools ... actually quite awesome.
However, I would like to create a table of contents. I have read the knitr and
r markdown instructions on TOC and I can create a TOC in a markdown document
but I cannot translate the command to a vignette -
Hello,
I've recently discovered the helpful dplyr package. I'm using the
'aggregate' function as such:
bevs <- data.frame(cbind(name = c("Bill", "Mary"), drink = c("coffee",
"tea", "cocoa", "water"), cost = seq(1:8), sex = c("male","female")));
bevs$cost <- seq(1:8)
> bevs
name drink cos
Hi
I wonder if it is easier to convert the dates to character format and then
reformat using gsub or the like
str(SampleData)
SampleData$date <- as.character(SampleData$date)
str(SampleData)
as.Date(
ifelse(nchar(SampleData[,"date"]) == 9, as.Date(SampleData[,"date"], format =
"%d-%b-%y"),
Alright kids, I think we should close this topic since we appear to be
getting further and further off-topic.
--
View this message in context:
http://r.789695.n4.nabble.com/Daily-Category-Revenue-Stacked-Bar-Chart-in-ggplot2-tp4710431p4710563.html
Sent from the R help mailing list archive at N
Below.
Bert Gunter
"Data is not information. Information is not knowledge. And knowledge
is certainly not wisdom."
-- Clifford Stoll
On Wed, Jul 29, 2015 at 3:43 PM, Hidden Markov Model
wrote:
> Alright thanks for clarifying. That's all a bit esoteric. Quite different
> from "basics off com
Alright thanks for clarifying. That's all a bit esoteric. Quite different
from "basics off computer use". None of the documentation anyone mentioned
actually contains any of this. If Nabble is so bad, then why does anyone use
it? It doesn't make sense. You should probably write a wiki going forwar
Further refining the vectorized (within a loop) exact string match
function, I get times below 0.9 seconds while maintaining error checking.
This is accomplished by removing which() and replacing 1:length() with
seq_along().
sub2 <- function(pattern, replacement, x) {
len<- length(x)
Hi Sarah,
Thanks for getting back to me.Here is an example of my data:SampleData <-
structure(list(id = 1:7, value = c(5813L, 8706L, 4049L, 5877L,
1375L, 2223L, 3423L), date = structure(c(4L, 3L,
2L, 1L, 7L,
On Jul 29, 2015, at 1:02 PM, Hidden Markov Model wrote:
> Alright, I think I understand what you guys are talking about. It is still
> not clear the relationship between R-help and Nabble since you guys haven't
> actually answered that.
Nabble's relationship to Rhelp? Nabble is an ongoing annoy
I'm assuming you actually want the date column to be character, not factor:
SampleData <- structure(list(id = 1:7, value = c(5813L, 8706L, 4049L, 5877L,
1375L, 2223L, 3423L), date = c("19-Dec-11", "07-Dec-11", "06/05/11",
"05/12/11", "31/12/2011", "10/19/2011", "01/22/2011")), .Names = c("id",
"val
On Wed, Jul 29, 2015 at 2:45 PM, farnoosh sheikhi via R-help
wrote:
> Hi Arun,
> Hope all is well with you. I have a data with a column for date.The date
> format is mixed. There are date values with Month/Day/Year format and values
> with Day/Month/Year format.I don't know how to unify it.I re
Hi Stella,
On Wed, Jul 29, 2015 at 1:14 PM, Stella Xu wrote:
>
> My question is about how to select and rearrange the data to a new data
> frame
> Here is an example:
> Samples counts time
> A 10 3
> A 12 4
> A 11 3
>
Hi Arun,
Hope all is well with you. I have a data with a column for date.The date format
is mixed. There are date values with Month/Day/Year format and values with
Day/Month/Year format.I don't know how to unify it.I really appreciate your
help.Thanks.
[[alternative HTML version dele
My question is about how to select and rearrange the data to a new data
frame
Here is an example:
Samples counts time
A 10 3
A 12 4
A 11 3
B 12 4
B 10 5
C
Alright, I think I understand what you guys are talking about. It is still
not clear the relationship between R-help and Nabble since you guys haven't
actually answered that.
Again, the best way to provide proper advice is to actually quote to portion
of the website you are sending people to, i.e
> On 29-07-2015, at 20:37, Hidden Markov Model
> wrote:
>
> No, I'm not confused. I just posted on R help website.
The R help website is NOT on Nabble. You posted from Nabble as can be seen
from your message.
It can also be seen in what the internet browser displays. It is what we see in
ou
Since there IS NO R-help website that you can post on, you are definitely being
confused by the Nabble website. This is a MAILING list that you interact with
by sending emails to r-help@r-project.org, not a website forum. The trouble
with Nabble is that it does confuse users, and breaks the cont
No, I'm not confused. I just posted on R help website. I don't know how to
use the email client to do anything which you are speaking of. If you would
like the posts to be made in an alternative way, then you will need to
provide clear direction. Sending someone to a help page which doesn't
referen
Then why do your messages contain the Nabble footer:
View this message in context:
http://r.789695.n4.nabble.com/Daily-Category-Revenue-Stacked-Bar-Chart-in-ggplot2-tp4710431p4710540.html
Sent from the R help mailing list archive at Nabble.com.
I think you are confused. You should be looking at
Hi John,
Great thanks for the examples! I am not sure what you are referring to when
you say a post from Nabble - I posted this directly on R-help. I actually
never heard of Nabble.
Stacked Bar charts are great for when you have a lot of moving parts and
need to be able to zero in on one of them
Hello,
I'm trying to execute a python script within R (3.2.1 x 64) with the
PythonInR package. I would like to download an order of satellite images
from Nasa using a python script (
http://landsat.usgs.gov/documents/espa_bulk_downloader_v1.0.0.zip) but I
have no success. I first run the pyExecfil
Thank you everyone for taking the time to reply.
Thanks Martin and Hervé for your solutions.
Now I just need to remember to check for NA match.
--
View this message in context:
http://r.789695.n4.nabble.com/indices-of-mismatch-element-in-two-vector-with-missing-values-tp4710497p4710518.html
Se
Hi,
Nope. My point is that color pairs red-green, yellow-violet and blue-orange are
physically on the opposite sides of the wheel.
I'm not 100% satisfied with this circle, because three of greens and reds are
so near each other. But this is the best solution thus far :-)
The number of colors, 24
As models become more complex it becomes harder to distinguish
different parts and their effects. Even for a straight forward linear
regression model if X1 and X2 are correlated with each other then it
becomes difficult to distinguish between the effects of X1^2, X2^2,
and X1*X2. In your case the
Is this what you mean?
z <- data.frame(a=1:3,b=letters[1:3],row.names=letters[1:3])
zlist <- list(one=z,too =z)
for(i in 1:2){print(zlist[[i]],row.names=FALSE); cat("\n")}
a b
1 a
2 b
3 c
a b
1 a
2 b
3 c
... which could obviously be within a function.
Cheers,
Bert
Bert Gunter
"Data i
This might help:
http://bit.ly/1MUP0Lj
On Wed, Jul 29, 2015 at 11:00 AM, jpara3
wrote:
> ¿How can i set up a study with random forest where the response is highly
> imbalanced?
>
>
>
> -
>
> Guided Tours Basque Country
>
> Guided tours in the three capitals of the Basque Country: Bilbao,
>
Beats me. You can print a single data frame with
print(dat1, rownames = FALSE) but it is not clear to me how to do it within a
function.
I am sure someone who actually know what they are doing will be along in a
moment. Sorry not to have been of more help.
John Kane
Kingston ON Canada
-
1. Please post in plain text, not HTML.
2. Please do your homework. Data frames (the class of the result of
dcast) **always** have row names. ?data.frame for details.
3. Read up on S3 methods if you have not done so already (any good R
tutorial will tell you about them, including the "Intro to R
Here is a small example. it is not the real data I am working on but this
can help
#Chick weight example
names(ChickWeight) <- tolower(names(ChickWeight))
chick_m <- melt(ChickWeight, id=2:4, na.rm=TRUE)
class(chick_m)
test = function(data){
i = 1
table = list()
table [[i]] <- dcast(chick_
There is confusion here. apply() family functions are **NOT**
vectorization -- they ARE loops (at the interpreter level), just done
in "functionalized" form. Please read background material (John
Chambers's books, MASS, or numerous others) to improve your
understanding and avoid posting erroneous c
¿How can i set up a study with random forest where the response is highly
imbalanced?
-
Guided Tours Basque Country
Guided tours in the three capitals of the Basque Country: Bilbao,
Vitoria-Gasteiz and San Sebastian, as well as in their provinces. Available
languages.
Travel planners f
Thank you for your suggestion. Is there any open source api that won't
rate-limit it?
On Tue, Jul 28, 2015 at 9:38 PM, boB Rudis wrote:
> You should use ggmap::revgeocode (it calls google's api) and google
> will rate-limit you. There are also packages to use HERE maps
> geo/revgeo lookups
>
>
First
http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example
and http://adv-r.had.co.nz/Reproducibility.html
Second. It is very annoying to have posts come in from Nabble. Very few R-help
readers use it and the total context of some post to R-help is usually lost.
HI Frederic,
Can you supply a small example of the problem?
John Kane
Kingston ON Canada
> -Original Message-
> From: ntfr...@gmail.com
> Sent: Wed, 29 Jul 2015 14:15:58 +0300
> To: r-help@r-project.org
> Subject: [R] Removing display of R row names from list.
>
> Dear All,
>
> Is the
Try restarting R-Studio. I have found that every once in a while it seems to do
something squirrelly but I have never isolated the problem enough to do a
report.
Otherwise,perhaps run R in a terminal and see if it will load the data from
there to check if the file is actually okay.
John Kane
Quite, but apparently not a boisterous one?
John Kane
Kingston ON Canada
-Original Message-
From: cfly...@ncsu.edu
Sent: Mon, 27 Jul 2015 14:35:06 -0400
To: jrkrid...@inbox.com
Subject: Re: [R] VIF threshold implying multicollinearity
No actually it is a quiet good paper! :)
On Mon, Ju
The solution is to create a new tkbind function that has not argument
tkbind(img,"","")
--
View this message in context:
http://r.789695.n4.nabble.com/Stop-tkbind-tp4710476p4710517.html
Sent from the R help mailing list archive at Nabble.com.
__
R-
Dear All,
Is there a way to not include the row names when creating the list? Thanks!
Regards,
Frederic.
Frederic Ntirenganya
Maseno University,
African Maths Initiative,
Kenya.
Mobile:(+254)718492836
Email: fr...@aims.ac.za
https://sites.google.com/a/aims.ac.za/fredo/
[[alternative HT
Not any ideas?
Thanks!
--
View this message in context:
http://r.789695.n4.nabble.com/Stop-tkbind-tp4710476p4710514.html
Sent from the R help mailing list archive at Nabble.com.
__
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
ht
data<-read.csv("https://raw.githubusercontent.com/sjkiss/Survey/master/mlogit.out.csv",header=T,sep=",";)
--
View this message in context:
http://r.789695.n4.nabble.com/How-to-read-CSV-from-web-tp4710502p4710513.html
Sent from the R help mailing list archive at Nabble.com.
> On 28 Jul 2015, at 15:53 , Sarah Goslee wrote:
>
> Sure, there are lots of ways to do everything in R. But mixing in
> apply muddles the issue, since apply() and sweep() use different logic
> to determine MARGIN.
Actually, apply() and sweep() were designed together and use exactly the SAME
l
> Hervé Pagès
> on Tue, 28 Jul 2015 23:07:14 -0700 writes:
> On 07/28/2015 09:58 PM, Peter Alspach wrote:
>> One way
>>
>> seq(test1)[-which(test1==test2)]
> One question is whether 2 NAs should be considered to match or not.
> The OP doesn't tell but I
Thanks, Dan.
Your codes work fine. But I have tens of countries UK, JP, BR, US...,
each of which has ten columns a1, a2, ..., a10 of data. So a little more
automation is needed.
I have been trying to make a list of each country's data and use sapply
thing
to get
UK JP
2009 Q2
49 matches
Mail list logo