Search Archives
Search tips
from:Name
Search by author name, e.g. from:Duncan Murdoch
"exact phrase"
Match an exact phrase
word1 word2
Match messages containing both words
Date range
Use the date pickers to filter results to a time period
Use the list dropdown to narrow results to a specific mailing list. Combine from: with other terms to filter by author and content.
Problem solved. Many many thanks for your ideas!! (this site is very stimulant) :) -- View this message in context: http://r.789695.n4.nabble.com/built-a-lower-triangular-matrix-from-dataframe-tp4390813p4393619.html Sent from the R help mailing list...
Sorry, I just realized that it's not a lower triangualr matrix, but an upper triangular matrix! But still the solution/s should be rather similar in both cases. http://r.789695.n4.nabble.com/file/n4391127/matrix2.png I...
Hi again, I just realized that in this solution there is something funny on the position the values in the matrix, they don't really correspond to the position indicated in the subscripts... However, David Winsemius has given a valid...
Thank you very much Michael and Berend for your ideas and feddback. I apologize for my mistakes. It's true that I still have much to learn (and I sometimes forget what I read). I'll surely use the dput...
Hello! I'm trying to build a lower triangular matrix (with zeros in the diagonal) from a particular dataframe. The matrix I have to construct has 203 rows and 203 columns and that makes 20503 values to be included within...
Hi Rui, Thank you very much for your idea. It works!!! I converted my dataframe into a vector (I first removed the header and the first and second column) and then tried your solution: > data <- as.vector(as.matrix(read...
Hello all, I'm trying to group several consecutives rows (and assigning them the same value) while leaving some of the rows empty (when a certain condition is not fulfilled). My data are locations (xy coordinates), the date/time at...
Hi Tsjerk! Thanks for your quick reply! It's a nice way to built a lower triangular matrix with zeros in the diagonal, but what I can't work out is *how to include the values of the third column...
Hi Michael, Your answer was very interesting, thank you! However, I tried it and the result was: > df <- read.table(file="df.txt", head=T, sep="\t") > df i j k 1 1 2 5.2 2 1 3 9...
Hi David, What an good solution. It works perfectly and it's really simple. (I only removed the "1+" in ncol=1+max(j), it already has 6 columns) My result has been: > df <- read.table(file="df.txt", head...
Dear R experts, I'm using the adehabitatHR package in order to perform a kernel analysis and estimate the home range of my input data (GPS relocations of 42 individuals). I've done the analysis for one of the individuals...
Can't find what you're looking for? Try searching with Google .