Giter VIP home page Giter VIP logo

pyzeta's People

Contributors

christofs avatar dkltimon avatar juliadudar avatar morethanbooks avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pyzeta's Issues

offer randomized contrast

Offer the option to run a comparison not on a meaningful partitioning of the data, but on a random one, for a better understanding of the level of differences to be expected if the partitioning is not meaningful.

Add sampling of n segments from each document

This is an idea of AZ. Make sure that longer documents don't skew the results by sampling a fix number of segments from each document. In this way, each document will have an equal weight in the overall Zeta score of a group of texts. It does mean some loss of information, because more text is discarded.

Add parameter file

Move basic parameter settings to a separate, plain text settings file to be loaded by run_pyzeta.

Address deprection warning in calculate.py

warnings.warn(DEPRECATION_MSG_1D, DeprecationWarning)
/usr/local/lib/python3.5/dist-packages/sklearn/preprocessing/data.py:321: DeprecationWarning: Passing 1d arrays as data is deprecated in 0.17 and will raise ValueError in 0.19. Reshape your data either using X.reshape(-1, 1) if your data has a single feature or X.reshape(1, -1) if it contains a single sample.

KeyError: "None of ['idno'] are in the columns"

I tried running run_pyzeta with doyle and roman20 corpus and I get this error:

Traceback (most recent call last):
  File "run_pyzeta.py", line 101, in <module>
    calculate.main(datafolder, dtmfolder, metadatafile, separator, contrast, logaddition, resultsfolder, segmentlength, featuretype, absolutefreqs, relativefreqs, binaryfreqs)
  File "/Users/reiterns/Documents/Projects/fanfiction/pyzeta/scripts/calculate.py", line 375, in main
    idlists = make_idlists(metadatafile, separator, contrast)
  File "/Users/reiterns/Documents/Projects/fanfiction/pyzeta/scripts/calculate.py", line 36, in make_idlists
    metadata.set_index("idno", inplace=True)
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/pandas/core/frame.py", line 4391, in set_index
    raise KeyError("None of {} are in the columns".format(missing))
KeyError: "None of ['idno'] are in the columns"

Any ideas?

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.