0
votes

I looked for an answer to this question but wasn't able to find one that exactly matched with my particular problem.

First of all, I am using gnuplot (since I haven't found this answer also using Julia...)

The issue:

I have a file (test.dat) wich is basically an array. It has 100 rows and 50 columns. Each row represents a bar chart that I need to plot. IN each column of that row, there is the value or magnitude of the bar. Simple.

So I need to plot all rows (a total of 100 bar charts) in the same graph. Also, I need it to be with transparency, so I can see all the bar-charts. Can anybody help me with this problem?

1

1 Answers

0
votes

You use this to set transparency:

set style fill transparent solid 0.5

0.5 is the level of transparency.

But if I understood the question correctly, your data format may be problematic. With the following data:

1 10 50
2 20 40
3 30 30
4 40 20
5 50 10

so 2 charts, each with 5 elements, and the following gnuplot instructions:

set terminal pngcairo truecolor size 800, 600
set output "data.png"

set style fill transparent solid 0.5
set style data boxes

set boxwidth 0.5

plot 'data.txt' using 1:2 title 'foo' linetype rgb 'red', \
             '' using 1:3 title 'bar' linetype rgb 'web-blue'

you will get this: enter image description here