Ric,
load and open and other system primitives seem to work ok. One specific
problem I saw was when working page 17 of Fractals, Visualization and
J. After loading '~addons/media/image3/view_m.ijs' (which worked
correctly) the book says to execute
(pal;s) write_image 'temp/temp.png'
which gives a _1 error result. So I tried again, thinking it needed a
home directory reference:
(pal;s) write_image '~temp/temp.png'
Same result. Oddly, changing the file name extension gave an internal
dll error, which caused me to think the cover function had an issue.
So, after spending some time learning how to manipulate directories I
came upon the correct formulation:
(pal;s) write_image jpath '~temp/temp.png'
I suspect the problem is buried somewhere in or below write_image, but
since my main purpose here is to get familiar with J and not so much to
diagnose problems in the examples I continued on. However, it left a
little tickle in my brain to someday figure out when where and how ~ in
a file name gets resolved. I came close to dropping Cliff an email
about this, but got distracted and just added it to my notes as
something to figure out later.
Tom
Sherlock, Ric wrote:
---List wrote:
I understand about implementation specific differences, but
the errors I
was referring to were more subtle usage errors. For example, I have
seen a number of examples where a file name is specified without jpath
in front, and this seems to confuse the name resolution routines on
Windows boxes.
Can you point to specific examples where this is a problem?
Note that some verbs (eg. load open) apply jpath themselves, so the following
should work fine on all systems:
open '~system/
load '~system/packages/math/mean.ijs'
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm