Displaying 20 results from an estimated 46 matches for "value3".
Did you mean:
value
2010 Dec 17
4
How to arrange the data
Dear R helpers
I have one data as given below.
date value1 value2 value3
30-Nov-2010 100 40 61
25-Nov-2010 108 31 88
14-Sep-2010 11 180 56
I want the following output
date name amount
30-Nov-2010 value1 100
30-N...
2006 Apr 06
1
reshape question
Hi,
I have a data fram like this:
date column1 column2 column3 value1 value2 value3
1-1 A B C 10 5 2
2-1 A B D 5 2 0
3-1 A B E 17 10 7
How can I reshape it to:
date column1 column2 column3 v x
1-1 A B C value1 10
1-1 A B C value2 5
1-1 A B C value3 2
2-1 A B D value1 5
2-1 A B D value2 2
2-1 A B D value3 0
3-1 A B E value1 17
3-1 A B E value2 10
3-1 A B E value3 7
Thx!
Regards...
2011 May 05
3
Alter a line in a file.
Hi all R users
Ive got a file that contains diffrent settings in the manor of:
setting1="value1"
setting2="value2"
setting3="value3"
setting4="value4"
.
.
.
What I want to do is open the file and change the value of a specific
setting
like wanna change setting4="value4" -> setting4="value5" and then save the
file again.
setting1="value1"
setting2="value2"
setting3=&quo...
2007 Feb 24
3
gsub: replacing a.*a if no occurence of b in .*
...ing to read a number of XML files using xmlTreeParse(). Unfortunately,
some of them are malformed in a way that makes R crash. The problem is that
closing tags are sometimes repeated like this:
<tag>value1</tag><tag>value2</tag>some garbage</tag></tag><tag>value3</tag>
I want to preprocess the contents of the XML file using gsub() before feeding
them to xmlTreeParse() to clean them up, but I can't figure out how to do it.
What I need is something that transforms the example above into:
<tag>value1</tag><tag>value2</tag>&l...
2012 Mar 01
2
Rscript example
Hi there,
I am trying to find an example how to use Rscript
Let's suppose I want to pass 3 arguments (I don't want [options] and -e
[expressions] as described in help)
*on the command line
myRscript.R -arg1=value1 -arg2=value2 -arg3=value3
*In the script
#! /path/to/Rscript
args = commandArgs(TRUE);
>From what I see args is just a string, do I do things correctly ?
--
View this message in context: http://r.789695.n4.nabble.com/Rscript-example-tp4436130p4436130.html
Sent from the R help mailing list archive at Nabble.com.
2007 Jun 12
3
Read Windows-like .INI files into R data structure?
I need to process some datasets where the configuration information was
stored in .INI-like files, i.e., text files with sections like this:
[Section1]
var1=value1
var2=value2
[Section2]
A=value3
B=value4
...
>From Google and other searches I haven't found any package, or function
within a package, that reads .INI files into an R list, or other data
structure.
Any suggestions, or do I need to write my own?
efg
Earl F. Glynn
Stowers Institute for Medical Research
2007 Jun 06
2
lookup in CSV recipe
...ven so I thought it might be useful.
I thought about adding it to the wiki, but thought I should check here
first.
# lookup items from a CSV file
# v0.1 - 2007/06/06
# Adrian Bridgett, Opsera Ltd.
# file in the format of:
# colname1, colname2, colname3,... (must be first line)
# key1, value2, value3,...
# key2, value4, value5
#
# lookup_csv(filename,key1,colname3) will then return value3
#
# TODO:
# proper CSV parsing (e.g. quoting)
# regexp on the value?
# return a supplied default if row not found?
# add Excel and Openoffice support
module Puppet::Parser::Functions
newfunction(:lookup_csv...
2012 Nov 17
2
Using cbind to combine data frames and preserve header/names
I have a dataframe that has a header like so:
class value1 value2 value3
class is a factor
the actual values in the columns value1, value2 and value3 are 0-255, I wish to binarize these using biclust.
I can do this like so:
binarize(dataframe[,-1])
this will return a dataframe, but then I lose my first column class, so I thought I could combine it like so:
datafram...
2009 Sep 10
2
tranform a table?
...lo everyone,
i'm new to R, so i hope you dont mind a fairly basic R question. we're
using R to manipulate the results of SQL queries and create an HTML output.
I'm starting with a table that looks essentially like this:
Name Field1 Field2
John value1 value2
Jane value3 value4
My table is stored as a dataframe. I'd like to efficiently produce an
output that iterates through each row, transposes it and outputs an HTML
table (one per row). like this:
Name: John
Field1: value1
Field2: value2
Name: Jane
Field1: value3
Field2: value4
I can accomplish this...
2009 May 19
2
Feature request: "database show" from manager API
Hi,
In ASTDB, I've got a rather long list of entries like:
/FamilyA/Key1 Value1
/FamilyA/Key2 Value2
/FamilyA/Key3 Value3
...
Instead of sending several DBGet queries (and parsing every response), I'm
wondering if a single "database show" or "database show family" query could
be implemented.
Alternative if to use ssh ("asterisk -rx "database show FamilyA") but I'm
not certai...
2009 Aug 10
1
manipulating text to generate different formulas to use in nls()
...autogenerate" the arguments needed by nls() depending on that
number.
For example, when there are two sinusoids:
> nls( y ~ mu + A1 * cos(2*pi*f1*x - P1) + A2 * cos(2*pi*f2*x - P2), data = some.xy.data,
start = list( mu=some.value0, A1=some.value1, P1=some.value2, A2=some.value3,
P2=some.value4, f1=some.value5, f2=some.value6 ) )
Adding a third sinusoid, the model and the starting parameters needed become:
> nls( y ~ mu + A1 * cos(2*pi*f1*x - P1) + A2 * cos(2*pi*f2*x - P2) + A3 * cos(2*pi*f3*x - P3),
data = some.xy.data, star...
2007 Nov 23
1
what''s the best way to deal with class/inheritence
...#39;'class bundle-xxxx { $var1="value2"; include other_classes }''
site-global.pp
only one pp containing values for a given site installation (multiple server, one customer, for example)
--> currently it''s defined as a ''node site-globals { $var1="value3" }''
nodes/
"node xxx" statements, one by individual physical server.
--> currently it''s defined as a ''node xxxx inherits site-global { $var1="value4"; include bundle-yyyy }''
this is working quite well BUT for the variables parts....
2020 Aug 14
2
TDB database commands (TDB used by SAMBA)
...ere I want to store
basically 3 information:
IP address , Name, TimeStamp - where IP would be the KEY and
"NAME,TIMESTAMP" would be the VALUE.
I am using the tdbtool to insert/store data successfully (like the example
below)
tdbtool myfile.tdb store "key1" "value1,value2,value3,value4"
The problem is when I want to READ the information back. It brings
hexadecimal code in a strange format. (see below)
tdbtool myfile.tdb show "key1"
key 4 bytes
key1
data 27 bytes
[000] 76 61 6C 75 65 31 2C 76 61 6C 75 65 32 2C 76 61 value1,v alue2,va
[010] 6C 75 65 33 2C...
2015 Oct 28
4
RFC: Supporting macros in LLVM debug info
...h:
--------------------------------------------------------------------------------------
1. #define M4 Value4
--------------------------------------------------------------------------------------
=========================================================
Command line:
clang -c -g -gmacro -O0 -DM3=Value3 -include myfile2.h mainfile.c
AST
=========================================================
MacroDecl 0xd6c5c0 <<invalid sloc>> <invalid sloc> __llvm__ defined
MacroDecl 0xd6c618 <<invalid sloc>> <invalid sloc> __clang__ defined
... <More compiler macros>...
2012 Oct 10
2
reading in a (very simple) list from a file
...ich then fail when I try to apply
it to my simple task.
Anyway, all I want to do is read in a series of key-value pairs from a file.
I thought a list would be a good way to keep these, such that I could access
them like: listname$key
I was imagining a file like this:
key1 value1
key2 value2
key3 value3
...
(the keys will always be character strings, the values might be other types,
but they will always be single items)
I won't bore you with all the things I've tried. I'm sure I'm overlooking
something basic and simple, but I would greatly appreciate it if someone
could help me o...
2011 Jul 27
3
Searching using prefixes
Hi guys
I'm trying to figure out how I can use probabilistic searching on a
given field within a document; I've written to the list about this
before, but haven't quite figured out what's required and, following a
little research, I think I understand what I need to do but I'd like a
clarification on this.
o We have a database of a number of documents, with fields: title,
2009 Jul 29
3
Newbie in R: Reading .txt files and storing the 'numbers' in a vector
Hello everybody,
I'm a newbie in R and just went through an introduction class recently.
Here's my problem.
I have 2 text files (.txt) with plain numbers ('doubles' for those who
know c++) ordered into 2 columns as below:
coordinate1 value1
coordinate2 value2
coordinate3 value3
... ...
coordinateN valueN
I would like to write a small programme in which i would:
1. take all values of file 1 and store them in a vector
2. substract to those all values of file 2 (one by one) and store the
result in a new vector
3. Create a sliding window of chosen size and calculate th...
2011 Jul 25
2
Lattice: distance of tick labels from axis line
Hi, I am doing fine editing on a lattice plot, now have the Y-axis title in
the correct position, but the tick labels are too far from the axis line. I
looked at the help documentation but could not find how to change this. This
seems to be easy to do in basic plots with "at=c(value1, value2, value3)" .
Is there some equivalent in lattice? Thanks.
--
View this message in context: http://r.789695.n4.nabble.com/Lattice-distance-of-tick-labels-from-axis-line-tp3693014p3693014.html
Sent from the R help mailing list archive at Nabble.com.
2008 Feb 29
2
while loop syntax help
...p is greatly appreciated.
I need to sort through a vector (x) and identify the point at which 2 successive values become smaller than the previous value.
I've written a "while" statement that I think should work. It's should basically say: If value 1 > value 2 and also > value3, then == row(Value 1). Else, go to the next Value. However, output returns "NULL", no matter how I've modified the syntax.
Thanks in advance for any help.
Zack
#############################
x <- c(5,5,7,6,5,4,3) x <- data.frame(x)
y <-length(x)-2counter <- 1
output =...
2015 Nov 03
3
RFC: Supporting macros in LLVM debug info
...h:
--------------------------------------------------------------------------------------
1. #define M4 Value4
--------------------------------------------------------------------------------------
=========================================================
Command line:
clang -c -g -gmacro -O0 -DM3=Value3 -include myfile2.h mainfile.c
AST
=========================================================
MacroDecl 0xd6c5c0 <<invalid sloc>> <invalid sloc> __llvm__ defined
MacroDecl 0xd6c618 <<invalid sloc>> <invalid sloc> __clang__ defined
… <More compiler macros>...