Re: Newbie question

*To*: mathgroup at smc.vnet.net*Subject*: [mg25308] Re: Newbie question*From*: Yossi Lonke <jrl16 at po.cwru.edu>*Date*: Tue, 19 Sep 2000 03:45:35 -0400 (EDT)*Organization*: Dept. Mathematics, CWRU*References*: <8q3dvc$kbb@smc.vnet.net>*Sender*: owner-wri-mathgroup at wolfram.com

Hello, One way to it is this: Map[{#[[1]],1/#[[2]]}&, data], Or, in even more cryptic form: {#[[1]], 1/#[[2]]}& /@ data The expression {#[[1]], 1/#[[2]]}& is a pure function, which receives {x,y} (or longer lists) as input and returns {x, 1/y}, and you simply map that function to your list. Yossi Lonke Jose M Lasso wrote: > Hi Mathgroup, > > I have some numerical data: data:={{x,y},{x1,y1},{x2,y2}....{xn,yn}}, > I want to transform the data like this: > data1:={{x,1/y},{x1,1/y1},{x2,1/y2}....{xn,1/yn}}, how can I do this > transformation? Thanx in advance. Regards > > Jose M Lasso -- ************************************************* Dr. Yossi Lonke Mathematics Department Case Western Reserve University 10900 Euclid Avenue Cleveland, Ohio 44106 216 368-5423 http://www.cwru.edu/artsci/math/lonke/home.html *************************************************