comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Array Dimensions and WRITE_GIF
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: array dimensions [message #24578 is a reply to message #10642] Sun, 08 April 2001 20:13 Go to previous messageGo to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Richard G. French (rfrench@wellesley.edu) writes:

> Now that you mention SMOOTH, one of my pet peeves is that
> y=SMOOTH(array,n) gives an error message when n=1. There are lots of
> instances where the degree of smoothing is calculated on the fly,
> and one common instance is that you want no smoothing at all - i.e.
> just give me the original array, unsmoothed. I've ended up writing
> my own routine MYSMOOTH which is identical to smooth except that
> it does not barf when n=1. Perhaps this has been changed recently,
> but I don't think so. Does anyone have a good explanation for why
> n=1 does not have the expected behavior of returning the array
> unsmoothed? Or is there a keyword I have not been noticing that
> can handle this case?

Having had some modest experience these past few years
writing programs for public consumption, allow me to
make an observation or two.

I don't know how it is done in the real world, but
in my world a program idea is generated as a result
of a problem I have encountered (usually more than once)
in my own work. I come up with what I almost always
mistakenly believe is a clever idea and I code it up.

The program stays at this stage for some indeterminate
amount of time, usually until someone runs into a similar
problem and asks a question on the newsgroup. "Oh", I think,
"I have a clever solution to *that* problem. I'll clean
it up for them and offer it on my web page."

In the course of "cleaning it up", I usually discover
that my clever solution is really not as clever as I
thought it was and that it tends to work only in the
narrow confines of its original purpose. So I
make it more general. In fact, I usually try to imagine
all the ways it might be used.

Now, I am known in some circles as having a pretty
fertile imagination, but I have to admit that one of the
things that would *never* occur to me if I was writing
a SMOOTH function is that someone would use it if they
*didn't* want to smooth anything. Are you sure it would
have occurred to you?

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: A third-party example
Next Topic: Problem with ".cdf" files on Windows

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 20:08:33 PDT 2025

Total time taken to generate the page: 0.00451 seconds