Optional AltAnalyze Dependencies to be Installed
The compiled versions of AltAnalyze (Windows, Mac OSX and Ubuntu) should run immediately after extraction, however, the source code implementations may require additional Python modules installed. These are:
- Required: Python version 2.3 or greater
- Graphical User Interface requirement: Tkinter
- WikiPathways API visualization: lxml
- Faster Fisher Exact Test: Scipy
- Visualization output files: Matplotlib, Numpy, Scipy
- PNG viewing in the GUI: Python Imaging Library (PIL) ImageTk
- Statistical libraries for Combat: Patsy and Pandas
- Network visualization in igraph: igraph and cairo
These libraries can be installed from source code or from installers provided by the open-source project websites.
To determine if a pre-compiled version of AltAnalyze is compatible with your operating system, download the program and double-click the executable file name "AltAnalyze". The program can also be initiated from a terminal command-line (e.g., "./AltAnalyze in Linux). Feel free to contact us about any problems.
Instructions for Windows/Linux/Mac OS X
Mac OS X
By default, Mac OS X has Python installed along with Tkiner. Python version 2X should be default and used instead of python 3.
Windows
Install Python 2.7 from http://www.python.org. Tkinter is installed by default.
Linux (see Ubuntu below)
If python or tkinter is not installed, install Python 2.7 from http://www.python.org. Tkinter is installed by default. Test by typing python
at the terminal and then import tkinter
.
Cross-Platform Installation Options
Python and Tkinter are all that are needed for AltAnalyze to run, but other dependencies are required if you wish to visualize WikiPathways (suds, PIL), cluster or QC plots (Matplotlib, Numpy, Scipy) or speed up the Fisher Exact Test analysis (scipy). To install these, see the below instructions.
- Install setuptools: http://pypi.python.org/pypi/setuptools/
- Install suds:
sudo easy_install suds
- Install matplotlib:
sudo easy_install matplotlib
- Install numpy:
sudo easy_install numpy
- Install scipy:
sudo easy_install scipy
- Install Imagetk:
easy_install --find-links http://www.pythonware.com/products/pil/ Imaging
- Install patsy:
sudo easy_install patsy
- Install pandas:
sudo easy_install pandas
- Install fastcluster: recommend install from source
- Install igraph: recommend installer
- Install cairo: recommend install from source (see INSTALL file or here for Windows users)
- Install ordereddict (Python 2.6 or below) :
easy_install ordereddict
Instructions for Ubuntu
Adding support for python applications call Tk is particularly challenging on Ubuntu, since Python is installed but Tkinter is not. We recommend:
- Ensure all Ubuntu updates have been installed
- Install Tkinter:
apt-get install python-tk
(restart after) - Install setuptools:
sudo apt-get install python-setuptools
- Install suds:
sudo easy_install suds
- Install matplotlib:
sudo apt-get install python-matplotlib
- Install numpy:
sudo apt-get install python-numpy
- Install scipy:
sudo apt-get install python-scipy
- Install Imagetk:
sudo apt-get install python-imaging python-imaging-tk
- Install patsy:
sudo easy_install patsy
- Install pandas:
sudo easy_install pandas
- Install fastcluster:
sudo easy_install fastcluster
Note: Installing from source is necessary when apt-get
or easy_install
does not properly obtain all dependent libraries. To install from source use these commands:
python setup.py build
sudo python setup.py install
For igraph, install as described here
- This will install to the default system python (default or python installed by
apt-get
). If installed via other means (e.g., from source to /usr/local/bin), you will need to sym link the igraph folder from the equivalent system python version to your local installed and use the commandexport LD_LIBRARY_PATH=/usr/lib/
orexport LD_LIBRARY_PATH=/usr/local/lib/
if igraph gives an ImportError.
Developers Only
Both PyInstaller and cx_Freeze have been used to build AltAnalyze binary distributions. In general, PyInstaller works the best with the described patch for Ubuntu, whereas cx_Freeze will work for some but not all Ubuntu releases and configurations (e.g., compatible with 10.04).
- Install cx_Freeze from source (problems with
apt-get
) (may require libssl-dev be installed) - OR download and extract PyInstaller 1.6 (requires this patch)
- In the AltAnalyze main program directory (ensure .py files are in this root and not just Source_code), run:
python setup.py build
- Paste the files in the build/exe.linux directory into the AltAnalyze main program folder.
- Test the "AltAnalyze" executable file in a copy of the AltAnalyze directory prior to distribution.
Creating Compilers (advanced)
If you wish to create your own compiled version of AltAnalyze for distribution to your users (e.g., custom versions or unsupported operating systems), install the above and be mindful of the following:
- Customization of the
setup.py
file may be required for inclusion or exclusion of OS specific libraries (dll files). - See the
setup.py
script for run instructions on different operating systems. - The suds package folder must exist in the Python site-packages folder (not just the egg - zip must be extracted).
- Issues with matplotlib external dependencies may occur (see existing
setup.py
files for details). - Issues with conflicting dependencies may occur on some OSs resulting in strange errors during binary creations. These include: the python library six may need to be called as site-packages/six/six.py rather than the egg file.
Potential Issues
- Pandas installs it's own dateutil which may cause errors to be displayed in the console and possibly other issues.
- Eggs are not well supported by py2exe