The matrix is generated by print.dist function ( getS3method("print", "dist") ).
You could try this:
d <- as.matrix(dist(matrix(rnorm(27), 9), diag = TRUE, upper = TRUE))
colnames(d) <- letters[1:9]
On Wed, Apr 13, 2011 at 1:29 PM, Radhouane Aniba wrote:
> Hi,
>
> I have a vector V of values
Hi,
I have a vector V of values I used to create a distance matrix using dist()
function with diag=TRUE and upper=TRUE parameters.
I would like to assign names in another vector on top of each column instead
of 1 2 3 4 ...
How can we do that ? is the distance matrix generated a data frame or a
m
2 matches
Mail list logo