Git Product home page Git Product logo

Comments (16)

kookma avatar kookma commented on June 12, 2024 1

Hi @certik I have not a MacOS machine to test and all my tests were on Windows and Ubuntu! but I will investigate!

@LKedward - would you have a look?

from ogpf.

certik avatar certik commented on June 12, 2024 1

Thanks @kookma for your help! I've installed gnuplot using Conda, so it would have to be fixed in Conda.

from ogpf.

certik avatar certik commented on June 12, 2024

I can debug this too. Thank you @kookma for the library!

from ogpf.

kookma avatar kookma commented on June 12, 2024

Thank you @certik! So please update me here! I am not sure but I think something goes wrong with wxt terminal (on MacOS) here!

from ogpf.

kookma avatar kookma commented on June 12, 2024

Also please test with qt terminal!

set terminal qt
set title "Some Math Functions"
set xrange [-10:10]
set yrange [-2:2]
set zeroaxis
plot (x/4)**2, sin(x), 1/x

See for example https://apple.stackexchange.com/questions/103814/cant-plot-with-gnuplot-on-my-mac

I had no issue report for wxt on MacOS and I assumed it should work as default terminal on Windows/Linux/MacOS.

Side note:

issue the below command to see what terminals are available on your system!

set terminal

from ogpf.

LKedward avatar LKedward commented on June 12, 2024

@LKedward - would you have a look?

Apologies, I don't have a Mac and so I wasn't able to test on MacOS unfortunately.

from ogpf.

kookma avatar kookma commented on June 12, 2024

@LKedward
No problem. It is not related to FPM! It seems something goes wrong with terminal!

Thank you!

from ogpf.

certik avatar certik commented on June 12, 2024

With qt I get:

gnuplot> set terminal qt
Terminal type is now 'qt'
gnuplot> set title "Some Math Functions"
gnuplot> set xrange [-10:10]
gnuplot> set yrange [-2:2]
gnuplot> set zeroaxis
gnuplot> plot (x/4)**2, sin(x), 1/x
Could not start gnuplot_qt with path /Users/certik/miniforge3/envs/gf/libexec/gnuplot/5.4
Did you set environmental variable GNUPLOT_DRIVER_DIR?
Could not start gnuplot_qt with path /Users/certik/miniforge3/envs/gf/libexec/gnuplot/5.4
Did you set environmental variable GNUPLOT_DRIVER_DIR?

from ogpf.

certik avatar certik commented on June 12, 2024

Here are the available terminals:

gnuplot> set terminal

Available terminal types:
       cairolatex  LaTeX picture environment using graphicx package and Cairo backend
           canvas  HTML Canvas object
              cgm  Computer Graphics Metafile
          context  ConTeXt with MetaFun (for PDF documents)
          domterm  DomTerm terminal emulator with embedded SVG
             dumb  ascii art for anything that prints text
              dxf  dxf-file for AutoCad (default size 120x80)
              emf  Enhanced Metafile format
         epscairo  eps terminal based on cairo
         epslatex  LaTeX picture environment using graphicx package
              fig  FIG graphics language V3.2 for XFIG graphics editor
              gif  GIF images using libgd and TrueType fonts
             hpgl  HP7475 and relatives [number of pens] [eject]
             jpeg  JPEG images using libgd and TrueType fonts
               mf  Metafont plotting standard
               mp  MetaPost plotting standard
             pcl5  PCL5e/PCL5c printers using HP-GL/2
         pdfcairo  pdf terminal based on cairo
           pict2e  LaTeX2e picture environment
              png  PNG images using libgd and TrueType fonts
         pngcairo  png terminal based on cairo
       postscript  PostScript graphics, including EPSF embedded files (*.eps)
          pslatex  LaTeX picture environment with PostScript \specials
            pstex  plain TeX with PostScript \specials
         pstricks  LaTeX picture environment with PSTricks macros
               qt  Qt cross-platform interactive terminal
          sixelgd  sixel using libgd and TrueType fonts
              svg  W3C Scalable Vector Graphics
          tek40xx  Tektronix 4010 and others; most TEK emulators
          tek410x  Tektronix 4106, 4107, 4109 and 420X terminals
          texdraw  LaTeX texdraw environment
         tkcanvas  Tk canvas widget
          unknown  Unknown terminal type - not a plotting device
            vttek  VT-like tek40xx terminal emulator
            xterm  Xterm Tektronix 4014 Mode

from ogpf.

kookma avatar kookma commented on June 12, 2024

Here are the available terminals:

Hi @certik - the report shows you have not wxt terminal installed! but you have qt Qt cross-platform interactive terminal
So technically to this point you should be able to plot using qt

from ogpf.

kookma avatar kookma commented on June 12, 2024

Could not start gnuplot_qt with path /Users/certik/miniforge3/envs/gf/libexec/gnuplot/5.4
Did you set environmental variable GNUPLOT_DRIVER_DIR?
Could not start gnuplot_qt with path /Users/certik/miniforge3/envs/gf/libexec/gnuplot/5.4
Did you set environmental variable GNUPLOT_DRIVER_DIR?

When you start a clean session of gnuplot using the below command shall display your default terminal

show terminal

By the way you have qt terminal but it can not call it correctly!

To see if you can plot, from your list of available terminal I use png terminal. Please execute the below example and let me know if you get the correct output

set terminal png size 400,300
set output 'test.png'
set title "Some Math Functions"
set xrange [-10:10]
set yrange [-2:2]
set zeroaxis
plot (x/4)**2, sin(x), 1/x

Gnuplot shall produce a test.png and you should get something like below
image

from ogpf.

certik avatar certik commented on June 12, 2024

The png terminal works and saves the png image.

The default terminal is qt, but it does not work due to the errors:

Could not start gnuplot_qt with path /Users/certik/miniforge3/envs/gf/libexec/gnuplot/5.4
Did you set environmental variable GNUPLOT_DRIVER_DIR?
Could not start gnuplot_qt with path /Users/certik/miniforge3/envs/gf/libexec/gnuplot/5.4
Did you set environmental variable GNUPLOT_DRIVER_DIR?

The executable /Users/certik/miniforge3/envs/gf/libexec/gnuplot/5.4/gnuplot_qt is there and seems to work (it opens up an application with a menu but no windows and I assume if it was used to plot something, it would show it). So I don't know what the problem is.

from ogpf.

kookma avatar kookma commented on June 12, 2024

Hi @certik - So gnuplot works fine! but not for qt terminal!
I am sorry I cannot help more as I do not have a MacOS. But as I see the error is not related with ogpf!
I have read on the net there are ways to install gnuplot+wxt on macos

https://stackoverflow.com/questions/13001847/wxt-terminal-for-gnuplot-on-mac-os-x

Please update me if you could resolve the issue!

from ogpf.

certik avatar certik commented on June 12, 2024

Well, I think it's always a good idea to provide instructions how to get a library (ogpf in this case) working on all platforms. Even though the problem is in gnuplot, it is related to ogpf, since ogpf depends on gnuplot to work.

from ogpf.

kookma avatar kookma commented on June 12, 2024

Well, I think it's always a good idea to provide instructions how to get a library (ogpf in this case) working on all platforms. Even though the problem is in gnuplot, it is related to ogpf, since ogpf depends on gnuplot to work.

I will add a line and refer users to consult http://www.gnuplot.info/ and have a working gnuplot on their system, then install ogpf! If I want to add all troubleshooting related to working gnuplot on all different operating systems (e.g linus, unix, Windows, macos, ...) it wont make sense here and we repeated gnuplot.info docs here!

Thank you!

from ogpf.

kookma avatar kookma commented on June 12, 2024

The png terminal works and saves the png image.

You can change wxt terminal in examples and use png instead. This will work for you! Also try to install wxt from https://stackoverflow.com/questions/13001847/wxt-terminal-for-gnuplot-on-mac-os-x and see how it works.

from ogpf.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.