This chapter gives a tutorial on using opus_core and urbansim in an interactive mode. Running Python interactively provides a convenient way for both beginners and experienced users to experiment with features and try out code. This tutorial is directed mainly to modelers, developers and other Opus users who will experiment with single components of the package and develop new features, rather than use the system of models as whole.
If necessary, install the supporting software, install Opus, and test the installation, as described in Appendix A.
You can start a Python session by opening a command window and
typing python at the command prompt. Alternatively, the
Wing IDE
also provides a convenient Python shell window.
Any code after the >>> is Python code. To follow along with this
tutorial, enter this directly into a Python interpreter. If you are unfamiliar
with Python, read Troubleshooting Python,
Section 23.5, at the end of this chapter before
proceeding through the code.