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
 Origin Forum
 Custom column calc on non numerical sorting?
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

FitmeGauss

2 Posts

Posted - 07/23/2020 :  05:47:18 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Hello,

I am in search for an origin functionality i am sure exists but i can't seem to find it.

Basically, i got a huge data with lots of discrete x-y coordinates of different particle trajectories. I want to do custom calculations on each particle such as euclidean distance, total distance, angles and more.

However, the input data is sorted in 3 columns (ID, x, y) where ID identifies the particule and is an arbitary denomination like RS123


Is there a way for origin to automatically do the calculation on each subset individually without bloating the sheet further up by splitting the data up?

Naturally, i tried using pivot tables to group together coordinates that belong to the same particle but origin requires at least one column source (henceforth i needed to include an extra column filled with the same criteria) and also doesn't allow custom calculation (only min/max...)
I'd figure it would be alot easier if the particules where named continously numerically but there should be a way to find matching coordinates without having to rename all of them right?

Shirley_GZ

China
Posts

Posted - 07/23/2020 :  06:47:25 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi FitmeGauss,

Yes, the pivot table needs at least one more column for Column Source.

Maybe you can try our Statistical on Columns tool which supports to set one column as grouping info, see https://www.originlab.com/doc/Origin-Help/Statistics-on-Columns
But I am not sure if this tool can output the calculation results you desired. Please just have a try and let me know whether this tool can implement what you want.

Thanks,
Shirley

Originlab Technical Service Team

Edited by - Shirley_GZ on 07/23/2020 06:50:33 AM
Go to Top of Page

FitmeGauss

2 Posts

Posted - 07/30/2020 :  4:38:06 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
quote:
Originally posted by Shirley_GZ

Hi FitmeGauss,

Yes, the pivot table needs at least one more column for Column Source.

Maybe you can try our Statistical on Columns tool which supports to set one column as grouping info, see https://www.originlab.com/doc/Origin-Help/Statistics-on-Columns
But I am not sure if this tool can output the calculation results you desired. Please just have a try and let me know whether this tool can implement what you want.

Thanks,
Shirley

Originlab Technical Service Team


Well, it does what i want to some extent if i can use one of the statistics functions pre build in and do all the calculations in thge sheet before(like summorizing the lenght of a trajectory based on polygon lenght). It is not possible to add custom functions to statistics right?

Is there a way to fetch the last index in a set which is of a certain value (if the data is monoton, but not strictly monoton)?
Go to Top of Page

cpyang

USA
1406 Posts

Posted - 07/31/2020 :  2:51:54 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Would you like to try our beta 2021 version?

In 2021 we are going to allow Python functions in column calculation.

Using Python it becomes very easy, and solution are typically easily found online for most problems.



In the example above, Python script is put into col(D)





and the corresponding LabTalk as:




CP
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