Displaying 20 results from an estimated 1100 matches similar to: "Formatting data, adding column names, use reshape, a newbie question"
2009 Apr 07
2
Using as.formula() with the reshape package cast
I am trying to use the "cast" function from the reshape package, where the
formula is not passed in directly, but as the result of the as.formula()
function.
Using reshape v. 0.7.2
I am able to properly melt() by data with:
> molten <- melt(x, id=1:2)
then I can properly cast with this:
> cast(molten, days ~ variable)
but if I try
> cast(molten,
2009 Aug 17
3
Reshape package: Casting data to form a grid
Dear R Users,
I'm trying to use the 'cast' function in the 'reshape' package to convert column-format data to gridded-format data. A sample of my dataset is as follows:
head(finalframe)
Latitude Longitude Temperature OrigLat p-value Blaney
1 -90 -38.75 NA -87.75 17.10167 NA
2 -90 135.75 NA -87.75 17.10167 NA
3 -90 80.25
2012 Apr 23
1
ggplot2 - geom_bar
Hello,
I've some problem with the ggplot2. Here's a small example:
--8<--
library(ggplot2)
molten <- data.frame(date=c('01','01','01','01',
'02','02','02','02'),
channel=c('red','red','blue','blue',
2011 May 31
1
reshape::cast: invalid 'yinds' argument
Hi,
I'm using reshape to cast molten data. When I use the following command, R
either crashes (when I use Notepad++) or gives an error (when I use Rgui or
source()), BUT the error occurs not always, maybe only on half the attempts:
w <- cast(v, id + code + productname + year + begin + end + specificDesc +
specificDesc2 ~ type)
Error in merge.data.frame(data, all.combinations, by =
2002 Jan 04
2
Strange problem from "identical" hosts
Long post.. sorry.
Ok.. I've got three systems, all running openssh-3.0.2p1. As a matter
of fact, they were installed from the same built tree, so I know they are
the same.
Here's the deal. I've got three systems, call them source1, source2 and
target. All are HP-UX 11.0 systems installed from the same tree.
Source1 and source2 both have thier root rsa pub keys in target's
2009 Jan 26
1
reshape problem: id and variable names not being recognized
Hi everyone. Long time listener, first-time caller here.
I have a data set that's been melted with the excellent reshape package, but
I can't seem to cast it the way I need to.
Here's the melted data's structure:
> str(mdat)
'data.frame': 6978 obs. of 4 variables:
$ VehType : Factor w/ 2 levels "Car","Truck": 1 1 2 1 1 2 1 1 1 1 ...
$ Year :
2018 Jun 02
2
encoding argument of source() in 3.5.0
In R 3.5.0 using the `encoding' argument of source() prevents loading
files from the internet; without the `encoding' argument files can be
loaded from the internet, but if they contain non-ascii characters,
these are not correctly displayed under MS-Windows (but they are
correctly displayed under GNU/Linux). With R 3.4.{2,3,4} there is no
such problem: using `encoding' the files are
2009 Nov 23
1
recognizing variable-names of cast() (package: reshape)
An embedded and charset-unspecified text was scrubbed...
Name: not available
URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20091123/3b4cbdd5/attachment-0001.pl>
2007 Oct 04
2
Failed to create Administrators, Failed to create Users
Hi,
Since I install Samba 3.0.23d on my Centos5 with kernel 2.6.18-8.1.10.el5 #1 SMP
I've the following messages in my logfile:
Oct 3 16:45:22 smbd[6174]: [2007/10/03 16:45:22, 0] auth/auth_util.c:create_builtin_administrators(785)
Oct 3 16:45:22 smbd[6174]: create_builtin_administrators: Failed to create Administrators
Oct 3 16:45:22 smbd[6174]: [2007/10/03 16:45:22, 0]
2009 Apr 30
1
Overlaying graphs from different datasets with ggplot
Dear R-users,
I recently began using the ggplot2 package and I am still in the process of
getting used to it.
My goal would be to plot on the same grid a number of curves derived from
two distinct datasets. The first dataset (called molten.data) looks like
this :
Column names : Perc, Week, Weight
P10 21 333.3554
P90 21 486.0480
P10 22 452.6347
P90 22 563.8263
P10 23 575.0960
P90
2018 Jun 04
3
encoding argument of source() in 3.5.0
>>>>> peter dalgaard
>>>>> on Sun, 3 Jun 2018 23:51:24 +0200 writes:
> Looks like this actually comes from readLines(), nothing
> to do with source() as such: In current R-devel (still):
>> f <- file("http://home.versanet.de/~s-berman/source2.R", encoding="UTF-8")
>> readLines(f)
> character(0)
2011 Jun 30
2
Points but no lines in qplot.
Dear R helpers,
I have molten data which is : -
> t3
Year variable value
1 2005 ICICI.Bank 274883700000
2 2006 ICICI.Bank 431668500000
3 2007 ICICI.Bank 595153000000
4 2008 ICICI.Bank 630857600000
5 2009 ICICI.Bank 545263300000
6 2005 HDFC.Bank 2658600000
7 2006 HDFC.Bank 7891000000
8 2007 HDFC.Bank 18031100000
9 2008
2010 Dec 22
2
how to pass object "members" in functions
Hello,
This is an R-syntax question when attempting to manipulate/access objects
when passed to a function.
I have a function attempting to just print values attached to an argument
object. For example,
printThis <- function(obj, parm2, parm3) {
print(obj.stuff1)
print(obj.stuff2)
}
where I've assigned stuff1 and stuff2 to the actual object passed as such
actualObject.stuff1 <-
2009 Sep 01
1
rsync and symlinks
Hi, I have one question regarding handling of symlinks in rsync. If I have
/source directory in which I have 100s of sub directories of directories and
each one has symlink to some directories out side the /source directory
hierarchy. Does rsync follows all those symlinks and syncs the data if I
specifies below rsync command?
rsync -avz /source/ remote.ky:/source/
source
|
| - source1
2011 Nov 29
2
Help with recast() syntax
Dear Help-Rs,
I have data similar to the following:
DF <- structure(list(X = 1:22, RESULT = structure(c(2L, 2L, 2L, 2L,
2L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
1L, 1L), .Label = c("NEG", "POS"), class = "factor"), YR_MO = c(201011L,
201012L, 201101L, 201102L, 201103L, 201104L, 201105L, 201106L,
201107L, 201108L, 201109L, 201011L,
2009 Mar 31
1
Reshape: 'melt' numerous objects
Dear R Users,
I'm trying to use the reshape package to 'melt' my gridded data into column format. I've done this before on individual files, but this time I'm trying to do it on a directory of files (with variable file names) - therefore I have to also use the 'assign' command. I have come up against a couple of problems however and am therefore seeking advice...
>
2008 Feb 15
2
For Subset or Reshaping the Table
Hi R users
I am a new user in the field of R.
I want to subset or reshape a data.frame.
For example I have a matrix like
A B C D E F G
a 1 2 3 4 5 6 7
b 4 6 8 9 5 5 6
c 3 4 4 4 3 3 6
d 1 2 4 6 8 8 9
e 5 6 7 8 9 2 3
I want to reshape the matrix in this format
Row Col Value
a D 4
a E 5
a F 6
. . ..
2007 Sep 26
3
guest not permitted to access share
Hi!
I have got the problem with my guest account. I can`t access to the share.
The OS is Centos 5 Linux 2.6.18-8.1.10.el5 #1 SMP
Version of krb5 is 1.5-29
This is my smb.conf:
[global]
# server string is the equivalent of the NT Description field
netbios name = SERVER
# workgroup = NT-Domain-Name or Workgroup-Name
workgroup = DOMAIN
realm = DOMAIN.NET
security = ADS
password server
2007 Sep 22
1
reshape() to wide with varying number of responses to fields
Hello,
I have a dataframe containing the following variables:
PID, Field, Value
Where PID refers to a unique individual, Field to a particular question, and
Value to a particular response to a question.
I?d like this in wide format, with a different row for each PID.
However.... there are differing numbers of Values associated with each
Field, for each PID.
For example, a Field question may
2023 Mar 01
1
Inherit Owner / Permissions
A user is attempting to use Windows Powershell get-childitem command to
copy files from one SMB directory to another.
*****************
Get-ChildItem -Path "W:\z_TestFiles\source1" -Recurse -File |
ForEach-Object {
Copy-Item -Path $_.FullName -Destination "X:\dest1"
}
*****************
When the command is run it creates the files as 0 byte files and then
errors.