Can someone try to find this library in Processing?


#1

No matter what I do, Processing just won’t find this library. No matter where I put it or how many renames I do, Processing can’t find it and I can’t find an alternative anywhere. I basically need it for the “Descriptive” class

http://adilapapaya.com/papayastatistics/

Anyone wanna give it a shot and then give a solution (or walkthrough of what/how they did) if they find whats wrong?


Problems adding Papaya Library
#2

The problem is that there is not jar inside the library folder inside the papaya folder.

sketchFolder
.........Libraries
................Papaya
.....................examples
.....................library      <-------EMPTY: no jar here :( 
.....................reference
.....................src

Kf


#3

So I assume that would make the whole library obsolete?

Not sure why they would give out a library with no .jar file if the whole thing won’t work

Is there a way to just take one class from this library or work around this? Thats all I need


#4

I will try to see if I can compile it but make a note I have not done this before. But yeah, it is not obsolete as the source code is there. One needs to build the jar files. In Processing, they provide an Eclipse template. I don’t use Eclipse atm so I see if I can get it going.

Tagging @quark or @Kevin Is it possible to build a library using std java commands aka using java CLI?

Kf


Why won't Processing find my library?
#5

@kfrajer Generally you need to put core.jar on your classpath, I use maven to build libraries, and you can obtain a usable core.jar from maven central thanks to Jeremy Laviole see his pom.xml here https://github.com/Rea-lity-Tech/Skatolo, where he builds a modified controlP5.


#6

@apratt Here is the library with the proper jar. Just add the proper folders following the structure dictated by the Processing Wiki and it should work. I tested this lib (and its jar) with P3.3.7 on Win 10 OS.

@monkstone I will have to give it a try another day as I have to go to bed. Thxs for sharing the link.

Kf


#7

Thanks you’ve been a big help.

Question. Which proper folders? You mean the “src, library, examples, reference” folders? I must be missing something

You talking about from here?


#8

In your previous post you have processing/libraries/papaya. So inside that folder you should find reference, examples, src and library. You need to place the jar inside the library folder. Or you can remove the whole papaya folder and use the one I loaded in github. Just ensure you follow the structure processing/Libraries/papaya.

On a side note. I tested the library using linearCorrelation.pde and it works. However, other provide exaples fail. The solution for most of them is easy. I tried UniqueExample.pde to show you what you need to do. You need to make sure all the PFonts are created inside setup(). The second change is to move the size() function from setup() to 'settings()`. After you implement these changes, everything should run smooth. So for instance (pseudo-code):

// font
PFont titleFont = createFont("Helvetica", 15, true);
PFont smallFont = createFont("Helvetica", 12, true);
PFont tinyFont = createFont("Helvetica", 9, true);

[...]  //Other fields

void setup() {
size(500, (int)yTop+(int)yHeight+60);

[...] //Other setup commands

Should be rewritten like this:

// font
PFont titleFont;
PFont smallFont;
PFont tinyFont;

[...]

void settings(){
  size(500, (int)yTop+(int)yHeight+60);
} 

void setup() {

[...]

titleFont = createFont("Helvetica", 15, true);
smallFont = createFont("Helvetica", 12, true);
tinyFont = createFont("Helvetica", 9, true);

Kf


#9

Thanks for the help. The code runs fine on my Mac. I get exactly what I want and the new window pops up clean, but I get an error when I run it on my Windows 7 PC. Not sure why that is. Its the same code, everything is in the same location. I posted a picture below to show the error I get. Anyone know why that is and a solution?


#10

This is a new problem. Please create a new post. I can only guess it is related to minim. To test, please run example code that comes with the Minim library.

Kf


#11

If you post between multiple sites, please link between them. This question has already been answered here:

@kfrajer Yeah you can definitely make a library without using Eclipse. But you don’t have to. I’d probably just drag the jar onto the Processing editor and let Processing work its magic automatically.


#12

I was having the same problem and could finally solve it thank to this post and at this one

Besides not downloading the library from this site, as suggested by @kfrajer, I added the papaya.jar file on this path C:\Program Files\Processing\core\library and it finally worked!