Hi Lee-

The PDL book is probably the closest to a
comprehensive intro to the capabilities and
use of PDL:

http://pdl.perl.org/content/pdl-book-toc.html

The above linked TOC has a link to the
sf.net download for the PDF file.  I see you
already have some responses regarding use
of PDL::NiceSlice syntax or the underlying
slice() method.

--Chris

On Wed, Jan 2, 2013 at 9:56 AM, Lee Goddard <[email protected]> wrote:
> I have been using PDL for about four hours now, and have got stuck with the
> following.
>
> I have the following from MATLAB:
>
> for i=1:length(in)
>     s(i,:)=exp(-((in(i)-bin_locations).^2)/sigma);
>   end
>
>
> I am having problems finding out how to translate to PDL the left-hand side
> of the assignment: s(i,:)
>
> Please would somebody advise?
>
> I looked at 'set' but it apparently only sets 'a single value inside a
> piddle' [1]. It also says it has been superseded by slice, but that man page
> says slice is used to 'extract a rectangular slice of a piddle, from a
> string specifier.'[2]
>
> Incidentally, is there a good book on PDL in general, or perhaps
> specifically for MATLAB users?
>
> Many thanks in anticipation
> Lee
>
> [1] http://pdl.perl.org/PDLdocs/Core.html#set
> [2] http://pdl.perl.org/PDLdocs/Slices.html#slice
>
> _______________________________________________
> Perldl mailing list
> [email protected]
> http://mailman.jach.hawaii.edu/mailman/listinfo/perldl

_______________________________________________
Perldl mailing list
[email protected]
http://mailman.jach.hawaii.edu/mailman/listinfo/perldl

Reply via email to