daru

https://github.com/sciruby/daru

Ruby

Data Analysis in RUby

Daru::DataFrame.from_plaintext

Read the database from a plaintext file. For this method to work,
the data should be present in a plain text file in columns. See
spec/fixtures/bank2.dat for an example.

== Arguments

* path - Path of the file to be read.
* fields - Vector names of the resulting database.

== Usage

  df = Daru::DataFrame.from_plaintext 'spec/fixtures/bank2.dat', [:v1,:v2,:v3,:v4,:v5,:v6]

Source | Google | Stack overflow

Edit

git clone [email protected]:sciruby/daru.git

cd daru

open lib/daru/dataframe.rb

Contribute

# Make a new branch

git checkout -b -your-name--update-docs-Daru--DataFrame-from_plaintext-for-pr


# Commit to git

git add lib/daru/dataframe.rbgit commit -m "better docs for Daru::DataFrame.from_plaintext"


# Open pull request

gem install hub # on a mac you can `brew install hub`

hub fork

git push <your name> -your-name--update-docs-Daru--DataFrame-from_plaintext-for-pr

hub pull-request


# Celebrate!