Skip to content

Commit

Permalink
release 0.1
Browse files Browse the repository at this point in the history
git-svn-id: http://pandas.googlecode.com/svn/trunk@97 d5231056-7de3-11de-ac95-d976489f1ece
  • Loading branch information
wesm committed Dec 26, 2009
1 parent 77ad265 commit d55fec2
Show file tree
Hide file tree
Showing 14 changed files with 216 additions and 91 deletions.
File renamed without changes.
2 changes: 1 addition & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include TODO LICENSE README
include TODO.txt LICENSE.txt README.txt
include setup.py setupegg.py
include examples/data/*
recursive-include examples *
108 changes: 108 additions & 0 deletions README.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
Installation from sources
=========================

In the pandas directory (same one where you found this file), execute:

python setup.py install

On Windows, you will need to install MinGW and execute

python setup.py install --compiler=mingw32

See

http://pandas.sourceforge.net/

For more information.

=============
Release Notes
=============

What it is
==========

pandas is a library for pan-el da-ta analysis, i.e. multidimensional
time series and cross-sectional data sets commonly found in
statistics, econometrics, or finance. It provides convenient and
easy-to-understand NumPy-based data structures for generic labeled
data, with focus on automatically aligning data based on its label(s)
and handling missing observations. One major goal of the library is to
simplify the implementation of statistical models on unreliable data.

Main Features
=============

* Data structures: for 1, 2, and 3 dimensional labeled data
sets. Some of their main features include:

* Automatically aligning data
* Handling missing observations in calculations
* Convenient slicing and reshaping ("reindexing") functions
* Provide 'group by' aggregation or transformation functionality
* Tools for merging / joining together data sets
* Simple matplotlib integration for plotting

* Date tools: objects for expressing date offsets or generating date
ranges; some functionality similar to scikits.timeseries

* Statistical models: convenient ordinary least squares and panel OLS
implementations for in-sample or rolling time series /
cross-sectional regressions. These will hopefully be the starting
point for implementing other models

pandas is not necessarily intended as a standalone library but rather
as something which can be used in tandem with other NumPy-based
packages like scikits.statsmodels. Where possible wheel-reinvention
has largely been avoided. Also, its time series manipulation
capability is not as extensive as scikits.timeseries; pandas does have
its own time series object which fits into the unified data model.

Some other useful tools for time series data (moving average, standard
deviation, etc.) are available in the codebase but do not yet have a
convenient interface. These will be highlighted in a future release.

Where to get it
===============

The source code is currently hosted on googlecode at:

http://pandas.googlecode.com

Binary releases can be downloaded there, or alternately via the Python
package index or easy_install

PyPi: http://pypi.python.org/pypi/pandas/

License
=======

BSD

Documentation
=============

The official documentation is hosted on SourceForge.

http://pandas.sourceforge.net/

The sphinx documentation is still in an incomplete state, but it
should provide a good starting point for learning how to use the
library. Expect the docs to continue to expand as time goes on.

Background
==========

Work on pandas started at AQR (a quantitative hedge fund) in 2008 and
has been under active development since then.

Discussion and Development
==========================

Since pandas development is related to a number of other scientific
Python projects, questions are welcome on the scipy-user mailing
list. Specialized discussions or design issues should take place on
the pystatsmodels mailing list / google group, where
scikits.statsmodels and other libraries will also be discussed:

http://groups.google.com/group/pystatsmodels
Empty file removed TODO
Empty file.
File renamed without changes.
83 changes: 25 additions & 58 deletions doc/make.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
"""
Python script for building documentation. This script was designed for
building the docs on windows, but may work on other platforms as well.
It has been tested on Ubuntu Jaunty and works there as well. If it does not
work for you and returns an error about finding sphinx-build then you need
to edit the first lines that define `sphinx_build` to point to where
sphinx-build is installed. On linux you can find out by typing
`which sphinx-build` at the command line.
Python script for building documentation.
To build the docs you must have all optional dependencies for statsmodels
installed. See the installation instructions for a list of these.
Expand All @@ -15,57 +9,26 @@
Usage
-----
python make.py clean
python make.py html
"""

import os
import glob
import shutil
import sys

# checks for sphinx-build binary these will find it if it is installed
# in sys.prefix+'/local/bin/' or
# in sys.predix+'/Scripts/'
if os.path.isfile(os.path.join(sys.prefix, 'Scripts', 'sphinx-build.exe')):
sphinx_build = os.path.join(sys.prefix, 'Scripts', 'sphinx-build.exe')
else:
sphinx_build = 'sphinx-build'

def check_build():
build_dirs = [
'build', 'build/doctrees', 'build/html', 'build/latex', 'build/plots']
for d in build_dirs:
try:
os.mkdir(d)
except OSError:
pass

rst_files = glob.glob("source/*.rst")
def sf():
'push a copy to the sf site'
os.system('cd build/html; rsync -avz . wesmckinn,pandas@web.sf.net:/home/groups/p/pa/pandas/htdocs/ -essh --cvs-exclude')

as_gen = "python sphinxext/autosummary_generate.py "

for rf in rst_files:
if os.system(as_gen + rf + " -p dump.xml -o source/generated"):
raise SystemExit("Failed to auto generate summary from %s" % rf)
def clean():
os.system('make clean')

def html():

check_build()
os.chdir('source')
if os.system(sphinx_build + ' -a -b html -d ../build/doctrees . ../build/html'):
raise SystemExit("Building HTML failed.")
os.chdir('..')
os.system('make html')

def latex():

check_build()
os.chdir('source')
# LaTeX format.
if os.system(sphinx_build + ' -a -b latex -d ../build/doctrees . ../build/latex'):
raise SystemExit("Building LaTeX failed.")

# Produce pdf.
os.chdir('../build/latex')

Expand All @@ -81,30 +44,34 @@ def latex():

os.chdir('../..')

def clean():
if os.path.exists('build'):
shutil.rmtree('build')

if os.path.exists('source/generated'):
shutil.rmtree('source/generated')

def all():
clean()
html()
latex()
# latex()

funcd = {
'html' : html,
'latex' : latex,
'clean' : clean,
'sf' : sf,
'all' : all,
}


small_docs = False

funcd = {'html':html,
'latex':latex,
'clean':clean,
'all':all,
}
# Change directory to the one containing this file
current_dir = os.getcwd()
os.chdir(os.path.dirname(os.path.join(current_dir, __file__)))

if len(sys.argv)>1:
for arg in sys.argv[1:]:
func = funcd.get(arg)
if func is None:
raise SystemExit('Do not know how to handle %s; valid args are'%(
raise SystemExit('Do not know how to handle %s; valid args are %s'%(
arg, funcd.keys()))
func()
else:
small_docs = False
all()
os.chdir(current_dir)
7 changes: 7 additions & 0 deletions doc/source/stats.ols.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Ordinary least squares
----------------------

.. automodule:: pandas.stats.ols
:members:
:undoc-members:
:show-inheritance:
7 changes: 7 additions & 0 deletions doc/source/stats.plm.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
OLS Panel regression
--------------------

.. automodule:: pandas.stats.plm
:members:
:undoc-members:
:show-inheritance:
25 changes: 25 additions & 0 deletions doc/source/stats.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,30 @@
Statistical tools
*****************

Least-squares entry-point
-------------------------

.. autosummary::
:toctree: generated/

ols

Class reference
---------------

.. currentmodule:: pandas.stats.ols

.. autosummary::
:toctree: generated/

OLS
MovingOLS

.. currentmodule:: pandas.stats.plm

.. autosummary::
:toctree: generated/

PanelOLS
MovingPanelOLS

24 changes: 12 additions & 12 deletions pandas/core/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ class DataFrame(Picklable, Groupable):
--------
DataMatrix: more efficient version of DataFrame for most operations
Example
-------
Examples
--------
>>> d = {'col1' : ts1, 'col2' : ts2}
>>> df = DataFrame(data=d, index=someIndex)
"""
Expand Down Expand Up @@ -125,8 +125,8 @@ def fromDict(cls, inputDict=None, castFloat=True, **kwds):
-------
DataFrame
Example
-------
Examples
--------
df1 = DataFrame.fromDict(myDict)
df2 = DataFrame.fromDict(A=seriesA, B=seriesB)
"""
Expand Down Expand Up @@ -462,8 +462,8 @@ def _combineFunc(self, other, func):
other : constant, array, or DataFrame/Matrix
func : function taking two arguments
Example
-------
Examples
--------
frame._combineFunc(otherFrame, lambda x, y: x + y)
"""
newColumns = {}
Expand Down Expand Up @@ -1042,8 +1042,8 @@ def apply(self, func, axis=0):
Function to apply to each column
axis : {0, 1}
Example
-------
Examples
--------
>>> df.apply(numpy.sqrt) --> DataFrame
>>> df.apply(numpy.sum) --> Series
Expand Down Expand Up @@ -1167,8 +1167,8 @@ def combineFirst(self, otherFrame):
----------
otherFrame : DataFrame / Matrix
Example
-------
Examples
--------
a.combineFirst(b)
a's values prioritized, use values from b to fill holes
Expand Down Expand Up @@ -1311,8 +1311,8 @@ def merge(self, other, on=None):
on : string
Column name to use
Example
-------
Examples
--------
This frame Other frame
c1 q1
a 1 0 v1
Expand Down
Loading

0 comments on commit d55fec2

Please sign in to comment.