- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Slope -Liner regression
I would like to calculate the slope in linear regression fashion. It should be a column formula. And the slope value should be single value (Averaged) for the below table.
Group | Subgroup | Log[V] | Log[T3] | Slope |
1 | a | 1.609438 | 7.953736 | Calculate slope for 1, a |
1 | a | 1.648659 | 6.777461 | |
1 | a | 1.686399 | 5.296072 | |
1 | b | 1.609438 | 8.953736 | Calculate slope for 1, b |
1 | b | 1.648659 | 7.777461 | |
1 | b | 1.686399 | 6.296072 | |
2 | a | 1.609438 | 17.95374 | Calculate slope for 2, a |
2 | a | 1.648659 | 16.77746 | |
2 | a | 1.686399 | 15.29607 | |
2 | b | 1.609438 | 38.95374 | Calculate slope for 2, b |
2 | b | 1.648659 | 37.77746 | |
2 | b | 1.686399 | 36.29607 |
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Slope -Liner regression
See the Linear Regression() function in the Help > Scripting Index for your formula. You might need to use a script, though. Subscripting the rows into groups of three might be difficult in a formula.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Slope -Liner regression
yes aware of this function. But want to want different slopes for different groups.
Combination of Group and SUBGROUP should have one unique value of slope.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Slope -Liner regression
Create new grouping column which is combination of Group and Subgroup to make it a bit easier. Then write a formula which will get values for specific group for LogV and LogT3 (many options for this). After this you can use Linear Regression function to get the estimates for slope. If you really want to see only one value for each group, then add check that if you are on first row of the group -> perform calculations, otherwise return missing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Slope -Liner regression
Forgot to mention. Slope should be Log[T3]/Log[V]