Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Hi I'm trying to write a shell script for plotting with gnuplot however I keep running into the error: bash: ./plot.sh: usr/bin/gnuplot: bad interpreter: No such file or directory I have checked the location 'usr/bin/gnuplot' and it definitely exists. I have also checked the permissions on the file and it is executable. I have also checked I can open gnuplot manually through the interpreter and encountered no problems here.

The following is my file:

#!usr/bin/gnuplot

reset
set terminal png
set output 'test.png'
set key inside left top vertical Right noreverse enhanced autotitles box linetype -1 linewidth 1.000
set samples 200, 200

set title "Arc trig"
set xlabel "x"
set ylabel "y"
set grid

plot [-3:5] asin(x),acos(x)

I'm running Ubuntu 12.10.

Any ideas would be much appreciated. Thanks.

share|improve this question
2  
typo in the shebang line, should be #!/usr/bin/gnuplot –  dawud May 4 '13 at 16:08
    
Consider making sure you have permission to write the png file to the current directory. –  Charlie Wilson May 4 '13 at 16:10
    
God I feel stupid, thanks so much problem solved. –  wookie1 May 4 '13 at 16:15

1 Answer 1

up vote 1 down vote accepted

Missed the "/" #!/usr/bin/gnuplot

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.