Re: [R] Counting Words

2015-01-22 Thread bgnumis bgnum
That' s perfect. Many thanks forma your appreciated help. El 22/01/2015 19:50, "Chel Hee Lee" escribió: > > x <- c("hola mundo mundo"); > > table(unlist(strsplit(x, " "))) > > hola mundo > 1 2 > > > > Is this what you are looking for? I hope this helps. > > Chel Hee Lee > > On 1/22/2015

Re: [R] Counting Words

2015-01-22 Thread MacQueen, Don
In addition to the other suggestions, which are fine for your simple example, I would take a trip to the CRAN Task View "Natural Language Processing", and see if there's anything there. -Don -- Don MacQueen Lawrence Livermore National Laboratory 7000 East Ave., L-627 Livermore, CA 94550 925-423

Re: [R] Counting Words

2015-01-22 Thread Ista Zahn
table(strsplit("hola mundo mundo", " ")[[1]]) On Thu, Jan 22, 2015 at 9:25 AM, bgnumis bgnum wrote: > Hi all, > > I want to cout the different words in a text. > > You see if the text is: "hola mundo mundo" the program will count: > > hola 1 > mundo 2 > > Is posible that Cran r have a similar fun

Re: [R] Counting Words

2015-01-22 Thread Chel Hee Lee
> x <- c("hola mundo mundo"); > table(unlist(strsplit(x, " "))) hola mundo 1 2 > Is this what you are looking for? I hope this helps. Chel Hee Lee On 1/22/2015 8:25 AM, bgnumis bgnum wrote: Hi all, I want to cout the different words in a text. You see if the text is: "hola mundo m

[R] Counting Words

2015-01-22 Thread bgnumis bgnum
Hi all, I want to cout the different words in a text. You see if the text is: "hola mundo mundo" the program will count: hola 1 mundo 2 Is posible that Cran r have a similar function? [[alternative HTML version deleted]] __ R-help@r-project.

Re: [R] counting words that are contained in a list

2014-02-15 Thread arun
Hi, May be this helps: vec1 <- c("victory","happiness","medal","war","service","ribbon", "dates") vec2 <- c("The World War II Victory Medal was first issued as a service ribbon referred to as the Victory Ribbon.", "By 1946, a full medal had been established which was referred to as the World W