search for: yr28

Displaying 10 results from an estimated 10 matches for "yr28".

Did you mean: r28
2023 Jan 14
2
Removing variables from data frame with a wile card
I have a data frame containing variables "yr3",...,"yr28". How do I remove them with a wild card----something similar to "del yr*" in Windows/doc? Thank you. > colnames(mydata) ? [1] "year"?????? "weight"???? "confeduc"?? "confothr" "college" ? [6] ... ?[41] "yr3"???????...
2023 Jan 14
2
Removing variables from data frame with a wile card
...e columns starting with yr: > > mydata <- mydata[, !grepl("^yr", colnames(mydata)), drop = FALSE] > >> On Sat, Jan 14, 2023 at 1:56 AM Steven T. Yen <styen at ntu.edu.tw> wrote: >> >> I have a data frame containing variables "yr3",...,"yr28". >> >> How do I remove them with a wild card----something similar to "del yr*" >> in Windows/doc? Thank you. >> >>> colnames(mydata) >> [1] "year" "weight" "confeduc" "confothr" "coll...
2023 Jan 14
1
Removing variables from data frame with a wile card
mydata[, -grep("^yr",colnames(mydata))] On Sat, Jan 14, 2023 at 8:57 AM Steven T. Yen <styen at ntu.edu.tw> wrote: > I have a data frame containing variables "yr3",...,"yr28". > > How do I remove them with a wild card----something similar to "del yr*" > in Windows/doc? Thank you. > > > colnames(mydata) > [1] "year" "weight" "confeduc" "confothr" "college" > [6] ....
2023 Jan 14
1
Removing variables from data frame with a wile card
...something like this to remove the columns starting with yr: mydata <- mydata[, !grepl("^yr", colnames(mydata)), drop = FALSE] On Sat, Jan 14, 2023 at 1:56 AM Steven T. Yen <styen at ntu.edu.tw> wrote: > > I have a data frame containing variables "yr3",...,"yr28". > > How do I remove them with a wild card----something similar to "del yr*" > in Windows/doc? Thank you. > > > colnames(mydata) > [1] "year" "weight" "confeduc" "confothr" "college" > [6] ....
2023 Jan 14
3
Removing variables from data frame with a wile card
...e columns starting with yr: > > mydata <- mydata[, !grepl("^yr", colnames(mydata)), drop = FALSE] > >> On Sat, Jan 14, 2023 at 1:56 AM Steven T. Yen <styen at ntu.edu.tw> wrote: >> >> I have a data frame containing variables "yr3",...,"yr28". >> >> How do I remove them with a wild card----something similar to "del yr*" >> in Windows/doc? Thank you. >> >>> colnames(mydata) >> [1] "year" "weight" "confeduc" "confothr" "coll...
2023 Feb 12
2
Removing variables from data frame with a wile card
...t;- mydata[, !grepl("^yr", colnames(mydata)), drop = FALSE] >> >> On Sat, Jan 14, 2023 at 1:56 AM Steven T. Yen <styen at ntu.edu.tw> >> <styen at ntu.edu.tw> wrote: >> >> >> I have a data frame containing variables "yr3",...,"yr28". >> >> >> How do I remove them with a wild card----something similar to "del yr*" >> >> in Windows/doc? Thank you. >> >> >> colnames(mydata) >> >> [1] "year" "weight" "confeduc" &...
2023 Jan 14
1
Removing variables from data frame with a wile card
...> > > > mydata <- mydata[, !grepl("^yr", colnames(mydata)), drop = FALSE] > > > >> On Sat, Jan 14, 2023 at 1:56 AM Steven T. Yen <styen at ntu.edu.tw> wrote: > >> > >> I have a data frame containing variables "yr3",...,"yr28". > >> > >> How do I remove them with a wild card----something similar to "del yr*" > >> in Windows/doc? Thank you. > >> > >>> colnames(mydata) > >> [1] "year" "weight" "confeduc" &qu...
2023 Jan 14
1
Removing variables from data frame with a wile card
...yr: >> >> mydata <- mydata[, !grepl("^yr", colnames(mydata)), drop = FALSE] >> >>> On Sat, Jan 14, 2023 at 1:56 AM Steven T. Yen <styen at ntu.edu.tw> wrote: >>> >>> I have a data frame containing variables "yr3",...,"yr28". >>> >>> How do I remove them with a wild card----something similar to "del yr*" >>> in Windows/doc? Thank you. >>> >>>> colnames(mydata) >>> ? [1] "year"?????? "weight"???? "confeduc"?? "c...
2023 Jan 15
2
Removing variables from data frame with a wile card
...th yr: >> >> mydata <- mydata[, !grepl("^yr", colnames(mydata)), drop = FALSE] >> >>> On Sat, Jan 14, 2023 at 1:56 AM Steven T. Yen <styen at ntu.edu.tw> wrote: >>> >>> I have a data frame containing variables "yr3",...,"yr28". >>> >>> How do I remove them with a wild card----something similar to "del yr*" >>> in Windows/doc? Thank you. >>> >>>> colnames(mydata) >>> [1] "year"?????? "weight"???? "confeduc"?? "con...
2023 Jan 15
0
Removing variables from data frame with a wile card
...yr: >> >> mydata <- mydata[, !grepl("^yr", colnames(mydata)), drop = FALSE] >> >>> On Sat, Jan 14, 2023 at 1:56 AM Steven T. Yen <styen at ntu.edu.tw> wrote: >>> >>> I have a data frame containing variables "yr3",...,"yr28". >>> >>> How do I remove them with a wild card----something similar to "del yr*" >>> in Windows/doc? Thank you. >>> >>>> colnames(mydata) >>> [1] "year" "weight" "confeduc" "c...