1 (edited by peter.kelly 2022-12-14 06:36:05)

Topic: Aplot graphs twice??

Hi Jeff,
I am trying Aplot for the first time and it's working great, easy to use too. However.... When I call display_plot, it graphs the data, closes that window and then opens a new window and graphs the data once more.  I am only using the basic code from the examples on-line and I am only calling this routine once. Any suggestions? I running it on Windows 11.
module plotter
    implicit none
    contains
subroutine meplot(p,q)
use aplot
use iso_fortran_env, only: wp=>real64, SP=>REAL32
implicit none

    type(aplot_t)::plot
    INTEGER , PARAMETER  ::  WSIZE = 1000   
    real(wp), dimension(wsize)::p, q
    real(sp), dimension(wsize)::x, y
    integer::i
    x=p;y=q     ! copy to real values
    plot = initialize_plot()
    call set_yscale(plot, minval(y)-1.0, 1.0+MAXVAL(Y))
    call set_xscale(plot, minval(x)-1.0, MAXVAL(x)+1.0)
    call set_title(plot, "Spline values")
    call set_xlabel(plot, "Round")
    call set_ylabel(plot, "Interpolated values")
   
    call set_seriestype(plot, 0, APLOT_STYLE_LINE)
    call add_dataset(plot, x,y)
    call set_serieslabel(plot, 0, "Football Scores")
   
    CALL set_seriescolor (plot, 0, 0, 0, 0)!  Set to black (item 0,r,g,b)
    call display_plot(plot)
    call destroy_plot(plot)
    return
    end subroutine meplot
end module plotter

Re: Aplot graphs twice??

I'm seeing it as well.  There were some Aplot changes in this release that must be causing it.  I'll look into the problem.

Jeff Armstrong
Approximatrix, LLC

Re: Aplot graphs twice??

I see it's fixed in the latest version. Thanks, Jeff