Try this:
d <- dist(USArrests)
ix <- which("Iowa" == labels(d))
d1 <- as.dist(as.matrix(d)[-ix, -ix])
On Thu, Jun 5, 2008 at 9:39 AM, Birgitle <[EMAIL PROTECTED]> wrote:
>
> I have a dist object containing 1 row that is only NA (not very intelligent
> to have bas dataset with one NA speciesa
Have still some problems
match("name", names(object))
[1] NA
which(names(object)=="Iname")
integer(0)
TestDist = object[-"name",]
Fehler in -"name" : ungültiges Argument für unären Operator
Error in -"name": invalid argument for unären (don`t know what this means)
operator
Thanks
Birgit
m
Birgitle a écrit :
Many thanks.
Is there a way to give me the number of the row, if I have the row name?
B.
a= object
'w' = name
> match('w', names(a))
# or
> which(names(a)=='w')
# or
but deletion should work with the number and/or with the name.
_
Additonally I got this error message
TestDist = Dist.HalbDisGow88[-147,]
Fehler in Dist.HalbDisGow88[-147, ] : falsche Anzahl von Dimensionen
(Error in Dist.HalbDisGow88[-147, ] : wrong number of dimensions
Birgit
mel-10 wrote:
>
> Birgitle a écrit :
>
>> I have a dist object containing 1
Many thanks.
Is there a way to give me the number of the row, if I have the row name?
B.
mel-10 wrote:
>
> Birgitle a écrit :
>
>> I have a dist object containing 1 row that is only NA (not very
>> intelligent
>> to have bas dataset with one NA speciesanyway).
>> I would like to delete t
Birgitle a écrit :
I have a dist object containing 1 row that is only NA (not very intelligent
to have bas dataset with one NA speciesanyway).
I would like to delete this row from this object.
newDistObject = distObject[-unwantedRow, ]
hih
__
R
I have a dist object containing 1 row that is only NA (not very intelligent
to have bas dataset with one NA speciesanyway).
I would like to delete this row from this object.
It may be not a difficult problem but I can not find a solution presently.
So I would be very happy if somebody could
7 matches
Mail list logo