swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swarm-Support] Saving EZGraph data to HDF5


From: Paul Johnson
Subject: Re: [Swarm-Support] Saving EZGraph data to HDF5
Date: Tue, 23 Aug 2005 10:50:06 -0500
User-agent: Mozilla Thunderbird 1.0.6-1.1.fc4 (X11/20050720)

I wonder if there's a Java working example to copy. You might look in the SwarmFaq directory.

In Objc I can point to easy examples.

There's a working example in Output.m in the Artificial Stock Market

  int run = [(Parameters *)arguments getRunArg];
  char hdfEZGraphName[100];
  if (run != -1)
    sprintf (hdfEZGraphName, "stockData-%d.hdf", run);
  else
    sprintf (hdfEZGraphName, "stockData-%s.hdf", timeString);


  hdf5container = [HDF5 createBegin: [self getZone]];
  [hdf5container setWriteFlag: YES];
  [hdf5container  setName: hdfEZGraphName];
  hdf5container = [hdf5container createEnd];

   priceGraph = [EZGraph createBegin: [self getZone]];
  [priceGraph setHDF5Container: hdf5container];

 [priceGraph setTitle: "Price v. time"];
  [priceGraph setAxisLabelsX: "time" Y: "price"];
  [priceGraph setWindowGeometryRecordName: "priceGraph"];
  [priceGraph enableDestroyNotification: self
              notificationMethod: @selector (_priceGraphDeath_:)];

  if (swarmGUIMode == YES)
    [priceGraph setGraphics: YES];
  else
    [priceGraph setGraphics: NO];

  priceGraph =  [priceGraph createEnd];

  // initiates the hdf5 output
  [priceGraph setFileOutput: YES];
  [priceGraph setFileName: "prices"]; //name inside hdf5 file



Dinis Gökaydin wrote:
Dear Swarm support,

Does anyone know how to save EZGraph data to HDF5 files? It looks simple but... when I try to create an instance of HDF5Impl the program crashes just because of that.

Thank you,

Dinis Gökaydin
_______________________________________________
Support mailing list
address@hidden
http://www.swarm.org/mailman/listinfo/support


--
Paul E. Johnson                       email: address@hidden
Dept. of Political Science            http://lark.cc.ku.edu/~pauljohn
1541 Lilac Lane, Rm 504
University of Kansas                  Office: (785) 864-9086
Lawrence, Kansas 66044-3177           FAX: (785) 864-5700


reply via email to

[Prev in Thread] Current Thread [Next in Thread]