How to pass datafile to pl scripts
I am new to ploticus and have to integrate with a project. I am going to
create many gantt charts, however, I did not find prefabs with gantt charts.
I am going to use pl scripts to generate, then, how could I parameterize
those input , such as: datafile path, legend...
pl -gif data=file x=1 y=2 -o result.gif
Can I do that?
Thanks very much
--- In email@example.com, "ywang1031" <ywang1031@...> wrote:
Does your gantt chart mean the deafult ones that are mostly used -
that aims to show the timing of tasks or activities as they occur over
time. If so, here is your solution.
Usage: pl -gif gantt.pl data=gantt.txt
// Specify data using proc getdata
/* not a part of this code. must be seperate*/
example file gantt.txt
y1 0 3
y2 3 8
y3 8 11
y4 11 12
// Define plotting are using proc areadef
rectangle: 1 1 4 1.8
xrange: 0 12
ycategories: datafield 1
// Define yaxis using proc yaxis
// Define xaxis using proc xaxis
stubs: inc 6
grid: color=red style=2
// Render the bars using proc bars
// with segmentfields tails
segmentfields: 2 3
I have tried it, the plot came oyt as expected. Try. I learnt this
only be trying.
- Yi, parameterizing your input is simple.
Write your script
Then invoke your script like this: pl myscript data=mydata ....
If you come up with a generalized robust gantt script I'd certainly
consider adding it as a new prefab.
On Tue, 6 Jun 2006, ywang1031 wrote:
> I am new to ploticus and have to integrate with a project. I am going to
> create many gantt charts, however, I did not find prefabs with gantt charts.
> I am going to use pl scripts to generate, then, how could I parameterize
> those input , such as: datafile path, legend...
> pl -gif data=file x=1 y=2 -o result.gif
> Can I do that?
> Thanks very much
Stephen C. Grubb scg@... x-6633
Scientific Software Engineer, The Jackson Laboratory
600 Main Street Bar Harbor, Maine 04609 USA