search for: tribo

Displaying 11 results from an estimated 11 matches for "tribo".

Did you mean: tribe
2008 Apr 07
5
How to pack my stuff into a package (library, collection)?
Hello, I am new useR, I have written some functions, which I currently use by "source"-ing them from the files. That's OK, but when I my functions start counting in the tens and hundreds I'd be glad to be able to type "help.search("my_obscure_fun")" and get a sensible reply. I also want to be able to load them as a package at startup and not have to
2008 Mar 22
2
More elegant multiplication or division of a data frame with a vector
Hello, I am importing some raw voltage multichannel measurements into an R data frame. I need to scale each column with the respective sensitivity for that channel. I figured how to do it, but I am curious if there isn't a more elegant way. Now I start with something like this: rawdata <- data.frame(rbind(c(1,2,3), c(4,5,6))) sens <- c(2,4,6) and I do this: data <-
2008 Feb 07
1
Bode plots in ggplot2
Hello, I am trying to figure out how to make a bode plot (a.k.a. bode diagram) in ggplot2. An example of such a diagram can be found here: http://meweb.ecn.purdue.edu/~me475/ctm/freq/bode2.GIF The example above shows the gain and phase characteristic of a linear system. In my case, I would like to compare visually several systems on the same diagram. The data in the data frame is arranged
2008 Mar 24
1
How to assign multiple return values
Hi, I am moving from MATLAB, where one can easily assign a number of output values from a function like this: [x,y] = myfun(a,b) Then variables x and y can be directly used in the caller workspace. I understand that R functions return a single argument, which could be a list. This in a way makes it possible to return multiple values with a single function call, but accessing the list variables
2008 Mar 25
1
Combining several mappings in ggplot2
Hello, I want to be able to make a plot that has several series with different color and linetype. Online documentation suggest that this is possible, but I haven't found how: "We can also create redundant mappings, mapping the same variable to multiple aesthetics. This is most useful when producing a graphic for both colour and black and white display." Here's what I have to
2008 Apr 04
1
How to access the attributes of a ggplot?
Hi, I am having some hard time figuring how to access (and modify) the properties of an object created by ggplot. I found 'ggopts', but it only returns some of the properties. Say I want to get the x- and y-axis limits, the tickmark locations, legend current position, the legend box and background color and set them to new values. Are these properties easily accessible (and modifiable)
2008 Mar 27
2
Rule for accessing attributes?
Hi ! I am a new user and quite confused by R-indexing. Make a list and get the attributes lst <- list(x = 1:3, y = 4:6, z = 7:9) attributes(lst) This returns: $names [1] "x" "y" "z" I can easily do: nm <-names(lst) or nm <-attr(lst,"names") which both return the assigned names of the named list 'lst', but why then this doesn't
2008 Feb 07
1
How to split a factor (unique identifier) into several others?
Hello, I have a data frame with a factor column, which uniquely identifies the observations in the data frame and it looks like this: sample1_condition1_place1 sample2_condition1_place1 sample3_condition1_place1 . . . sample3_condition3_place3 I want to turn it into three separate factor columns "sample", "condition" and "place". This is what I did so far: #
2008 Feb 25
1
Plotting series marked with a symbol on every nth data point, preferably in ggplot...
Hello! I am working with signals and a plot of several signals on the same axes can get quite messy. With lines that are very fractured, distinction by only the linestyle is not very clear. If I add symbols to the plot however, there are so many symbols, that they overplot and the whole plot is unreadable once again. I am looking for advice on how to make a plot with continuous lines and symbols
2008 Mar 26
2
Moving data between R and Matlab back and forth?
Hi to the list, I am trying to find a way to painlessly move structured data back and forth between R and Matlab (also Octave). For this purpose I found the R.matlab package great help. I wish to use a Matlab -v6 MAT file as an intermediary format, because it is well read by both Matlab and Octave. It is also well read by 'readMat' function in R.matlab package, but that is where I run
2008 Apr 04
0
Loosing attributes while binding data frames ...
Hello I want to keep track of my units in the data frame. I have been advised in the past on this list to create a new "units" attribute of the data frame and keep the units strings there. It works fine as long as I don't manipulate the data frame. Here's an example: -------------CODE BEGIN ----------------------- df1 <- data.frame(x = 1:10, y = runif(10))