sagarnikam123
2012-Feb-04 14:07 UTC
[R] want to drop levels of table vector & join two vector(appending)
is have vector from table stored in s variable> s[1] R P Y A C P V E S C D R R F S R S A D L T R H I R I Levels: A C D E F G H I K L M N P Q R S T V Y -- View this message in context: http://r.789695.n4.nabble.com/want-to-drop-levels-of-table-vector-join-two-vector-appending-tp4356851p4356851.html Sent from the R help mailing list archive at Nabble.com.
Petr Savicky
2012-Feb-04 15:16 UTC
[R] want to drop levels of table vector & join two vector(appending)
On Sat, Feb 04, 2012 at 06:07:01AM -0800, sagarnikam123 wrote:> is have vector from table stored in s variable > > s > [1] R P Y A C P V E S C D R R F S R S A D L T R H I R I > Levels: A C D E F G H I K L M N P Q R S T V YHi. Is as.character(), what you are looking for? as.character(s) [1] "R" "P" "Y" "A" "C" "P" "V" "E" "S" "C" "D" "R" "R" "F" "S" "R" "S" "A" "D" [20] "L" "T" "R" "H" "I" "R" "I" Petr Savicky.
David Winsemius
2012-Feb-04 18:19 UTC
[R] want to drop levels of table vector & join two vector(appending)
On Feb 4, 2012, at 9:07 AM, sagarnikam123 wrote:> is have vector from table stored in s variable >> s > [1] R P Y A C P V E S C D R R F S R S A D L T R H I R I > Levels: A C D E F G H I K L M N P Q R S T V YIf you want to join two factor vectors you need first coerce to character vectors, use c() on them and if you want a factor of the combined vector, then assign the result of factor() again.> > -- > View this message in context: http://r.789695.n4.nabble.com/want-to-drop-levels-of-table-vector-join-two-vector-appending-tp4356851p4356851.html > Sent from the R help mailing list archive at Nabble.com. > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code.David Winsemius, MD West Hartford, CT
Possibly Parallel Threads
- appending variable's values in table like fashion
- how to make hash?& append element, if i want following condition
- how to avoid writing index in write.table command
- how to append element at last position in array dynamically
- problem in matching numbers in two variables