The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum for Programming
 LabTalk Forum
 Normalize a column and calculation
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

Loick

France
14 Posts

Posted - 02/13/2009 :  11:11:21 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver. and Service Release (Select Help-->About Origin): 7,5
Operating System: XP pro

Dear all,

I try to find the command to normalize a column by the highest value.
I've looked on a huge part of the wiki.origin web page, but I don't clearly understand the labtalk syntax

I use this small script which need to be completed.

{
//add 2 column "normlum" & "VolInc"
work -c NormLum;
work -c VolInc;
}
{
//copy the value from column "Lum" to the new column (with the aim to normalize it after)
col(NormLum) = col(Lum);
col(VolInc) = col(vol)-(the smallest value in col(vol);
}

Thanks in advance for your help,

loick


Deanna

China
Posts

Posted - 02/15/2009 :  10:36:31 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi loick,

You mentioned that you want to "normalize a column by the highest value". Do you mean that after normalization, you want the maximum value to be "1" and the smallest value to be "0"?

Deanna
OriginLab Technical Services
Go to Top of Page

Loick

France
14 Posts

Posted - 02/17/2009 :  06:32:16 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
hello Deanna,

thanks for your reply.
In fact I have found the solution which is the following one:

quote:
sum(Data1_B); //compute max, min, etc.
Data1_C=Data1_B/sum.max; //divide column B by max, and put in C


this script allows to normalize a column by the highest value in it. So after running this script, the highest value after calculation will be 1.

You can also run this other script :

quote:
sum(Data1_B); //compute max, min, etc.
Data1_C=Data1_B-sum.min; //subtract column B by min, and put in C


Which subtracts to all column numbers the smallest value of an other column.

I hope it will be helpful for the other users of originlab.

Loick

Go to Top of Page

asvpuneet

India
1 Posts

Posted - 12/02/2009 :  1:26:46 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi...

can anyone help me in the script for applying the FFT smoothing method to the specified data set,and generalise it..so that it can be used as a formula...

thanks in advance,

regards
-puneet
Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000