Skip to content

UC-Irvine-Theory/SortingEvolvingData

Repository files navigation

Instructions
-------------------------------------------------------------------------------------------
To compile:
make
-------------------------------------------------------------------------------------------
To do a single run: 

Running ./Sort will give you the available options which are:
./Sort n sortAlg swapType numSwaps initialSeed startConfig sampleRate timeLimit [filename]

For example:
./Sort 1000 BUBBLE RANDOM 1 0 SORTED 100 10000

Or see runExample.sh

-------------------------------------------------------------------------------------------
Doing experiments and plotting:

Requires python libraries:
numpy:  http://www.numpy.org/
pyplot: https://matplotlib.org/api/pyplot_api.html

For experiments you can run several different runs using a convenient script
And then compare the plots

1) compile: 
make

2) make a directory results: 
mkdir ./results

3) Run the example script: 
sh ./runExample.sh

4) Run smartPlot.py (use python 2.7): 
python smartPlot.py results/

5) Choose what options you want to display. Examples:

100 BUBBLE SHUFFLE RANDOM 1

200 INSERTION SORTED-SHUFFLE RANDOM 1-2

100 * SHUFFLE * 1


-------------------------------------------------------------------------------------------
Please feel free to use this as you see fit!

Comments? Question? Email jjbesavi at uci.edu

Thanks!