From d3cf13f4d452cbb724db29383b673744519b0ef8 Mon Sep 17 00:00:00 2001 From: Jon Speicher Date: Thu, 25 Jul 2013 16:55:22 -0400 Subject: [PATCH] Modify goal to add command-line example. --- python/sw_engineering/SoftwareEngineering.ipynb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python/sw_engineering/SoftwareEngineering.ipynb b/python/sw_engineering/SoftwareEngineering.ipynb index 15119ed..c5bbb3b 100644 --- a/python/sw_engineering/SoftwareEngineering.ipynb +++ b/python/sw_engineering/SoftwareEngineering.ipynb @@ -56,7 +56,10 @@ "\n", "Up until now, most of our work has been in the IPython notebooks. As we discussed earlier, however, there are advantages to creating standalone Python modules and command-line scripts. These advantages include the ability to execute the programs frequently or in an automated fashion, as well as to centralize commonly-used bits of code for import into multiple programs.\n", "\n", - "Recalling the animal sighting data sets we worked with earlier, our goal will be to create a standalone utility, runnable from the command line, that finds the mean number of a particular animal seen per sighting of that animal. We will design our utility so that it will work with any properly-formatted data file and allow us to find the mean number of sightings for any animal contained within.\n", + "Recalling the animal sighting data sets we worked with earlier, our goal will be to create a standalone utility, runnable from the command line, that finds the mean number of a particular animal seen per sighting of that animal. We will design our utility so that it will work with any properly-formatted data file and allow us to find the mean number of sightings for any animal contained within without requiring us to edit the code to do so. We'd like it to work like this:\n", + "\n", + " $ ./mean_sighted.py big_animals.txt Wolverine\n", + " 11.7\n", "\n", "To achieve our goal, we'll approach the problem in a fashion typical of modern software engineering." ] -- 2.26.2