Coder Social home page Coder Social logo

Comments (14)

isnopitag avatar isnopitag commented on August 19, 2024 11

Well for the error of the icons download this .jar
and dont forget to include jmathio.jar https://github.com/yannrichet/jmathio

Link for the new jar ✌️
http://www.mediafire.com/download/wa3g3jfs6hv6aif/jmathplot.jar
Sorry for the mediafire link, I still no0b on Github ✌️

from jmathplot.

wamson avatar wamson commented on August 19, 2024 2

I have the same problem as "skipperguy12".
Exception in thread "main" java.lang.NullPointerException
at javax.swing.ImageIcon.(ImageIcon.java:217)
at org.math.plot.components.PlotToolBar.(PlotToolBar.java:61)
at org.math.plot.PlotPanel.addPlotToolBar(PlotPanel.java:149)
at org.math.plot.PlotPanel.(PlotPanel.java:59)
at org.math.plot.PlotPanel.(PlotPanel.java:67)
at org.math.plot.Plot2DPanel.(Plot2DPanel.java:31)
at online.InitialData.plotData(InitialData.java:15)
at online.TestGradDescent.main(TestGradDescent.java:10)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)

from jmathplot.

intfrr avatar intfrr commented on August 19, 2024

You have to include jmathio.jar https://github.com/yannrichet/jmathio

Note. Even this fix won't work; you will have to recreate the jar with icons folder from the source.

from jmathplot.

wamson avatar wamson commented on August 19, 2024

Oh, how to recreate the jar with icons folder from the source?

from jmathplot.

skipperguy12 avatar skipperguy12 commented on August 19, 2024

I'm sure this is related to me not "recreating the jar with icons folder from the source".
I have this issue (after including jmathio as a maven dependency).

Exception in thread "main" java.lang.NullPointerException
    at javax.swing.ImageIcon.<init>(ImageIcon.java:217)
    at org.math.plot.components.PlotToolBar.<init>(PlotToolBar.java:61)
    at org.math.plot.PlotPanel.addPlotToolBar(PlotPanel.java:149)
    at org.math.plot.PlotPanel.<init>(PlotPanel.java:59)
    at org.math.plot.PlotPanel.<init>(PlotPanel.java:67)
    at org.math.plot.Plot2DPanel.<init>(Plot2DPanel.java:31)
    at online.InitialData.plotData(InitialData.java:15)
    at online.TestGradDescent.main(TestGradDescent.java:10)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:483)
    at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)

Please explain how I can fix this. Thanks!

from jmathplot.

yannrichet avatar yannrichet commented on August 19, 2024

might be due to maven, not copying .png files in the jar, unlike ant. Probably need to move .png files in the src/main/resources/... directory. Let me some time to check that.

from jmathplot.

yannrichet avatar yannrichet commented on August 19, 2024

fixed in last push.

from jmathplot.

PaulojsGoncalves avatar PaulojsGoncalves commented on August 19, 2024

I place last version of jmathplot.jar with fix #16 into libraries of my project using Netbeans IDE. The method Plot2DPanel was now recognized but when I run project next exception was thrown:

Exception in thread "main" java.lang.NullPointerException
at javax.swing.ImageIcon.(ImageIcon.java:217)
at org.math.plot.components.PlotToolBar.(PlotToolBar.java:61)
at org.math.plot.PlotPanel.addPlotToolBar(PlotPanel.java:149)
at org.math.plot.PlotPanel.(PlotPanel.java:59)
at org.math.plot.PlotPanel.(PlotPanel.java:67)
at org.math.plot.Plot2DPanel.(Plot2DPanel.java:31)
at runningactivitiesannalyser.PlotRunningData.plotgraph(PlotRunningData.java:38)
at runningactivitiesannalyser.RunningActivitiesAnnalyser.main(RunningActivitiesAnnalyser.java:55)
Java Result: 1

How can I solve the problem and use this method?

Thank you!

from jmathplot.

yannrichet avatar yannrichet commented on August 19, 2024

Could you please check that .png files are located inside the jar file ?
Thx

from jmathplot.

PaulojsGoncalves avatar PaulojsGoncalves commented on August 19, 2024

There are no .png files inside jar fie. Only java classes can be found into jar.

from jmathplot.

wamson avatar wamson commented on August 19, 2024

oh, I put the latest source file into eclipse and export them as Jar. And then it works.
qq 20150719131410
qq 20150719131548

from jmathplot.

yannrichet avatar yannrichet commented on August 19, 2024

Ok, so I expect it is ok now. For those who still have problems, please cleanup your jar and rebuild from scratch.

from jmathplot.

rayryeng avatar rayryeng commented on August 19, 2024

@isnopitag Cheers. I didn't want to rebuild the source again. Thanks so much for making the JAR available!

from jmathplot.

rodanmuro avatar rodanmuro commented on August 19, 2024

I have the same problem
Exception in thread "main" java.lang.NullPointerException
at javax.swing.ImageIcon.(ImageIcon.java:217)
at org.math.plot.components.PlotToolBar.(PlotToolBar.java:61)
at org.math.plot.PlotPanel.addPlotToolBar(PlotPanel.java:149)
at org.math.plot.PlotPanel.(PlotPanel.java:59)
at org.math.plot.PlotPanel.(PlotPanel.java:67)
at org.math.plot.Plot2DPanel.(Plot2DPanel.java:31)
at graficasjava.GraficasJava.main(GraficasJava.java:21)
I download the last .jar and nothing
Any help? Thanks

from jmathplot.

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.