GithubHelp home page GithubHelp logo

mikekestemont / copia Goto Github PK

View Code? Open in Web Editor NEW
8.0 8.0 1.0 11.42 MB

Bias correction for richness in abundance data

License: Creative Commons Zero v1.0 Universal

Python 41.03% Jupyter Notebook 58.97%

copia's People

Contributors

fbkarsdorp avatar mikekestemont avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

kakdh

copia's Issues

survival_rate doesn't complete

Hi guys!

Running from IDLE 3.11.13 for Python 3.11.3 TK 8.6.12 on Mac M1, 2020, I cannot get the survival_rate function to complete. It runs and runs and never completes.

I tied unsuccessfully running it in many shapes, such as:
survival_ratio(abundance, method='chao1')
survival_ratio(abundance, method=“chao1”, n_iter=100, n_jobs=4)
survival_ratio(abundance, method=“chao1”, n_iter=10)

Anyone faces the same problem?

  • The same issue when I try to reproduce the FB results following the workflow described in jupyter notebooks.

Ideas for further tests

  • species accumulation curve should increase monotonically
  • Hill numbers: check q=1, q=2, q=3 etc. against known diversity indices
  • Example Egghe and Proot, iChao4, and ACE from original papers

plot

Create generic plot function, that determines what and how to plot on the basis of the keys in the dict provided.

Superfluous assertions

All diversity functions use the same assertion statement:

assert isinstance(x, np.ndarray) and x.ndim == 1

If we hide these functions from the user, and direct them to only use the main interface function diversity(), we can remove all assertions and add one to the diversity function.

signatures

Decide on signatures and **kwargs for the richness functions. (Jackknife as exception?)

f3-f4

Implemnt extension of chao1 that also looks at f3 and f4 (specifically for Middle English).

speciates estimate for N sightings?

I think the estimates from these methods are overly pessimistic for my data because some of the assumptions in the equations don't apply, and want to mitigate by calculating "species" estimate based on a separate estimate of missing activity ("sightings").

Is there a way to get this from the species_accumulation method or accumulation curve? Please advise.

custom labels in visualizations

Thanks for this great library, it was very timely for me.

I would like to be able to customize the species/sightings labels in the generated charts to reflect my actual data; didn't see anything in the docs about how this might be done.

logo

Ignore: dummy issue for making available the logo.
copia_logo

Boolean counting

Currently we use two ways to count the number of true elements in a NumPy array:

return x[x > 0].shape[0]

and

f1 = (x == 1).sum()

The first one using indexing is about twice as fast as the second one. However, an even faster solution is to use something like the following:

x = np.random.randint(0, 100, 1000)
np.count_nonzero(x > 0)

plotting vs computing

  • species accumulation contains more than plotting: split out?
  • same for evenness: split out computation and plotting?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.