Skip to content

Correlation between package output

2 messages · Fabio Monteiro, Sarah Goslee

#
Hello

I'm currently using the dbFD function of the FD package and i'm having some
things that I can't do.

Is there any way to check the relations between dbFD indexes?

Function cor for example? I can't manage to put the informations correctly

dbFD function gives a lot of output (indexes - nbsp, sing.sp, FRic, FEve,
FDiv, FDis and RaoQ). I want to see the relationships between the dbFD
output (nbsp, sing.sp, FRic, FEve, FDiv, FDis and RaoQ)

How should I type it?

Thank you

F?bio
1 day later
#
Hi Fabio,

Using the first example from ?dbFD

ex1 <- dbFD(dummy$trait, dummy$abun)

If you look at that help page, or at str(ex1), you'll see that the
returned object is a list with named components. So, you can access
the different indices just as you would access any other list. If
that's confusing to you, a good basic intro to R might be just the
thing.

Here are two ways to do so:
with(ex1, plot(nbsp, FRic))
cor(ex1$nbsp, ex1$FRic, use="pair") # the toy example has one NA value

You might in the future find R-sig-ecology to be a better place to ask
this sort of question.

Sarah


On Mon, Apr 11, 2016 at 9:20 AM, Fabio Monteiro
<fabio.monteiro1992 at gmail.com> wrote: