Displaying 20 results from an estimated 400 matches similar to: "Column create and Update using function"
2012 Jul 10
2
Count of elements in coulmns of a matrix
Could you please tell me what is the function or method to get count of
elements in all the columns in a matrix ?
for eg :-
ABC XYZ PQR
------ ----- ------
2 3 4
4 5
5 4 3
2
Result will be like
ABC XYZ PQR
------ ----- ------
2 4 3
Could you please help me
2013 Dec 08
2
How to evaluate sequence of strings like this
Hello Dear R community,
This is my problem. I have a data set (dataframe) called "mydat". It consist of 3 numerical variable. They are Centrecode, FSUSN and Round. I want to create unique ID by combining these 3 variables.
Follwing commands gives me what I need.
mydat1 <- paste(mydat$Centrecode, mydat$FSUSN,mydat$Round,sep="")
newds <- data.frame(mydat1)
For a
2003 Jun 06
2
little manipulation on data frame
Dear all,
I have data like 3 coulmns and many rows. Each entry
is less than 10.
Example
x y z
1 5 3 2
2 3 7 8
3 8 9 5
4 5 4 6
--------------------------
---------------------------
I have to sum entries of each coulmn (seperately) till
it be 10. This i have to start for each row. And I
want to assign no. of rows needed including that row
too(it to be 10 or 10+, the moment it exceeds 10, i
2013 Apr 29
2
Adding elements in data.frame subsets and also subtracting an element from the rest elements in data.frame
Dear R forum
I have a data.frame as
cashflow_df = data.frame(instrument = c("ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC","ABC", "ABC", "PQR", "PQR",
2008 Sep 17
5
inserting values for null
I have a dataframe D.F1
>dim (D.F1)
14351 9
This dataframe has values and for some 1000 rows it holds NULL values.I hace
found the missing values for about 500 and have those in another dataframe
D.F.sub.2
>dim(D.F.sub.2)
500 9
as dataframe is a subset of D.F1 the coulmn 1 in D.F.sub.2 is a subset of
D.F1.I have to insert the values in D.F1 in other fields while the coulmn 1
in both
2012 May 30
3
Separate Array Variable Content
Hi,
I am new in R,
i have a matrix like this
MyMatrix <-
*ABC PQR XYZ*
10 20 30
40 50 60
70 80 90
And, i have an array containing some conditions like this,
MyArray <- c("*ABC*>50","*PQR*<50","*ABC*<30 &* XYZ*<40")
"ABC>50"
"PQR<50"
"ABC<30 & XYZ<40"
2010 Feb 03
2
How to change output 'csv' file
Dear R helpers
After executing the R code, where the last few lines of the code are something like given below.
## Part of my R code
n = 20
........
.........
final_output = data.frame(Numbers = numbers, ABC = data1, XYZ = data2, PQR = data3)
write.csv(data.frame(Scenario = paste("Sc_", 1:n, sep = ""), final_output'), 'result.csv', row.names
2013 Jun 22
1
Announcing pqR - a faster version of R
I have released a new, faster, version of R, which I call pqR (for
"pretty quick" R), based on R-2.15.0. Among many other improvements,
pqR supports automatic use of multiple cores to perform numerical
computations in parallel with other numerical computations, and with
the interpretive thread. It also implements a true reference counting
scheme to reduce the amount of unnecessary
2010 Feb 10
4
Readjusting the OUTPUT csv file
Dear R helpers
I have some variables say ABC, DEF, PQR, LMN and XYZ. I am choosing any three varaibles at random at a time for my analysis and name these files as input1.csv, input2.csv and input3.csv. So if I choose variables say ABC, DEF and PQR, I am passing the specifications of these variables to input1.csv, input2.csv and input3.csv respectively.
This means in another case even if I
2012 Jul 11
4
MODE , VARIANCE , NTH PERCENTAILE
Hi,
Here i have an matrix like this,
ABC PQR XYZ MNO
------ ------- ------ --------
3 6 7 15
2 12 24 15
20 5 1 2
25 50 15 35
i need to get the
"MODE" - for each column-wise
"VARIANCE" - for
2010 Feb 10
3
Using R to format a file using a server (PDB to PQR file)
I am trying to write a program that uses R and takes a pdb file, and converts
it to a pqr file. This task is simple generally, using the website,
http://pdb2pqr-1.wustl.edu/pdb2pqr/. How do you use R to input a pdb file
(that is on hand) into the upload pdb file input, and run the website and
give the return file to be a pqr file. Thanks for your help.
--
View this message in context:
2013 Apr 26
2
Splitting data.frame and saving to csv files
Dear R Forum,
I have a data.frame as
df = data.frame(date = c("2013-04-15", "2013-04-14", "2013-04-13", "2013-04-12", "2013-04-11"),
ABC_f = c(62.80739769,81.04525895,84.65712455,12.78237251,57.61345256),
LMN_d = c(21.16794336,54.6580401,63.8923307,87.59880367,87.07693716),
XYZ_p = c(55.8885464,94.1358684,84.0089114,98.99746696,64.71083712),
2013 Jan 03
3
Make a column from columns
Hi,
I have a data matrix with 13 columns and 55 rows. First coulmn is year and
other are monthly values for 55 years.
Now i want to create a single column of all the values ( i e a single time
series column from column 2 to 13 ).
Is it the for loop that works here ...how ?
or how i can rearrange the data so that it becomes a times series column.
hope i made the question clear .
thank you,
2014 Jun 23
2
Unfixed bugs in latest R-patched
A new version of pqR is now available at pqR-project.org, which fixes
several bugs that are also present in the latest R Core patch release
(r66002). A number of bugs found previously during pqR development
are also unfixed in the latest R Core release. Here is the list of
these bugs that are unfixed in r66002 (including documentation
deficiencies), taken from the pqR bug fix and documentation
2015 Jul 14
3
Two bugs showing up mostly on SPARC systems
In testing pqR on Solaris SPARC systems, I have found two bugs that
are also present in recent R Core versions. You can see the bugs and
fixes at the following URLs:
https://github.com/radfordneal/pqR/commit/739a4960a4d8f3a3b20cfc311518369576689f37
https://github.com/radfordneal/pqR/commit/339b7286c7b43dcc6b00e51515772f1d7dce7858
The first bug, in nls, is most likely to occur on a 64-bit
2018 Nov 27
1
Subsetting row in single column matrix drops names in resulting vector
Dmitriy Selivanov (selivanov.dmitriy at gmail.com) wrote:
> Consider following example:
>
> a = matrix(1:2, nrow = 2, dimnames = list(c("row1", "row2"), c("col1")))
> a[1, ]
> # 1
>
> It returns *unnamed* vector `1` where I would expect named vector. In fact
> it returns named vector when number of columns is > 1.
> Same issue applicable
2012 May 25
4
Hash Table - Select and Change Data iniside Matrix
Hi,
Here i have been a matrix like this,
*NAME AGE PALCE TRUE/FALSE*
ABC 20 INDIA
XYZ 30 FRANCE
PQR 40 USA
MNO 30 KENIYA
DEF 25 AUSTRALIA
Here,* TRUE/FALSE* Column containing empty values.
So my requirement what is , need to change all the *TRUE/FALSE *column value
into "*TRUE*" where *AGE =
2008 Nov 05
3
Sort help
Geneset_name #Chromosome #Hit_in_Biomart
original_geneset_len Missing.genes
[1,] "AGUIRRE_PANCREAS_CHR12" "1" "51"
"59" "8"
[3,] "AGUIRRE_PANCREAS_CHR9" "1" "24"
"24"
2012 Aug 27
4
?nchar ?strsplit
Hi, my data frame is
x<-data.frame(ID=c("abc/def","abc/def/ghi","abc","mno/pqr/st/ab"))
I want to split my column ID using "/" as the place to split. How can I do that without telling the code how many sub-columns. I could use nchar(gsub("[^/]","",x$ID)) to get how many "/" are in each row of the column, but could
2005 May 30
4
Very simple traffic shaping script for H.323
Hello -
What I want to do seems very simple - I want to make sure any H.323
traffic gets processed before anything else entering or leaving this
network. The network has a videoconferencing device on the LAN at
192.168.16.4. A Linux firewall NATs an external IP Address to this
internal address and I have appropriate SNAT and DNAT rules that work.
The NAT and connection tracking rules all work