I want to execute shell commands inside if-block of Gnuplot. I tried the following:
datatype = 'full'
if ( datatype eq 'full' ) {
# Run shell command
!echo 'full'
} else {
# Run different shell command
!echo 'not full'
}
However, this gives me the error "filename.plt" line xx: invalid command
FYI, I already know instead of !echo, I can use print to do the same thing. That's not the point. I want to use shell commands with the symbol ! within the if-block. Any help will be appreciated.