Smooth a graph as if placing a rope across the data…?
up vote
3
down vote
favorite
I'm not sure how to correctly phrase this question, in fact if I knew exactly what I needed to ask I could probably work it out myself, so please bear with me.
What I need to do is smooth out a line, but weight the smoothing so that the smoothed graph never goes below the sampled data. What it would look like is if you put a thick rope over the sample points so that at the pointy bits the smooth curve of the rope would be close to the data, and at the low points of the data the smooth rope would be hanging in space. Like the red line here (it's a bit wrong at the top right, but you get the idea):
This is for some motion graphics I'm doing. The samples are from a timed transcript of someone speaking. As they speak their words appear, and then float off, driven by an expression. If I track the timing of the words exactly it's very jerky, if I take an average of the value over a period of time, e.g. five seconds I get the smoothness I want, but it looks bad when the text lags behind the speaking, but not so much if the speech lags behind the words.
interpolation data-analysis
add a comment |
up vote
3
down vote
favorite
I'm not sure how to correctly phrase this question, in fact if I knew exactly what I needed to ask I could probably work it out myself, so please bear with me.
What I need to do is smooth out a line, but weight the smoothing so that the smoothed graph never goes below the sampled data. What it would look like is if you put a thick rope over the sample points so that at the pointy bits the smooth curve of the rope would be close to the data, and at the low points of the data the smooth rope would be hanging in space. Like the red line here (it's a bit wrong at the top right, but you get the idea):
This is for some motion graphics I'm doing. The samples are from a timed transcript of someone speaking. As they speak their words appear, and then float off, driven by an expression. If I track the timing of the words exactly it's very jerky, if I take an average of the value over a period of time, e.g. five seconds I get the smoothness I want, but it looks bad when the text lags behind the speaking, but not so much if the speech lags behind the words.
interpolation data-analysis
1
+1 for a very interesting problem! I wonder if the convex hull would give you what you want? That would give you a piece-wise linear envelope, and there's probably some way you could get rid of the lower part of it. See en.wikipedia.org/wiki/Convex_hull_algorithms. Also, most numerical libraries would have numerical geometry algorithms in them, including the computation of convex hulls.
– Adrian Keister
Nov 28 at 14:07
Kinda disappointed that it's an interesting problem. I had hope that the answer would be 'oh that's just <mathematician's name> smoothing'
– stib
Nov 28 at 23:53
add a comment |
up vote
3
down vote
favorite
up vote
3
down vote
favorite
I'm not sure how to correctly phrase this question, in fact if I knew exactly what I needed to ask I could probably work it out myself, so please bear with me.
What I need to do is smooth out a line, but weight the smoothing so that the smoothed graph never goes below the sampled data. What it would look like is if you put a thick rope over the sample points so that at the pointy bits the smooth curve of the rope would be close to the data, and at the low points of the data the smooth rope would be hanging in space. Like the red line here (it's a bit wrong at the top right, but you get the idea):
This is for some motion graphics I'm doing. The samples are from a timed transcript of someone speaking. As they speak their words appear, and then float off, driven by an expression. If I track the timing of the words exactly it's very jerky, if I take an average of the value over a period of time, e.g. five seconds I get the smoothness I want, but it looks bad when the text lags behind the speaking, but not so much if the speech lags behind the words.
interpolation data-analysis
I'm not sure how to correctly phrase this question, in fact if I knew exactly what I needed to ask I could probably work it out myself, so please bear with me.
What I need to do is smooth out a line, but weight the smoothing so that the smoothed graph never goes below the sampled data. What it would look like is if you put a thick rope over the sample points so that at the pointy bits the smooth curve of the rope would be close to the data, and at the low points of the data the smooth rope would be hanging in space. Like the red line here (it's a bit wrong at the top right, but you get the idea):
This is for some motion graphics I'm doing. The samples are from a timed transcript of someone speaking. As they speak their words appear, and then float off, driven by an expression. If I track the timing of the words exactly it's very jerky, if I take an average of the value over a period of time, e.g. five seconds I get the smoothness I want, but it looks bad when the text lags behind the speaking, but not so much if the speech lags behind the words.
interpolation data-analysis
interpolation data-analysis
edited Nov 28 at 14:07
Adrian Keister
4,58251933
4,58251933
asked Nov 26 at 2:14
stib
1163
1163
1
+1 for a very interesting problem! I wonder if the convex hull would give you what you want? That would give you a piece-wise linear envelope, and there's probably some way you could get rid of the lower part of it. See en.wikipedia.org/wiki/Convex_hull_algorithms. Also, most numerical libraries would have numerical geometry algorithms in them, including the computation of convex hulls.
– Adrian Keister
Nov 28 at 14:07
Kinda disappointed that it's an interesting problem. I had hope that the answer would be 'oh that's just <mathematician's name> smoothing'
– stib
Nov 28 at 23:53
add a comment |
1
+1 for a very interesting problem! I wonder if the convex hull would give you what you want? That would give you a piece-wise linear envelope, and there's probably some way you could get rid of the lower part of it. See en.wikipedia.org/wiki/Convex_hull_algorithms. Also, most numerical libraries would have numerical geometry algorithms in them, including the computation of convex hulls.
– Adrian Keister
Nov 28 at 14:07
Kinda disappointed that it's an interesting problem. I had hope that the answer would be 'oh that's just <mathematician's name> smoothing'
– stib
Nov 28 at 23:53
1
1
+1 for a very interesting problem! I wonder if the convex hull would give you what you want? That would give you a piece-wise linear envelope, and there's probably some way you could get rid of the lower part of it. See en.wikipedia.org/wiki/Convex_hull_algorithms. Also, most numerical libraries would have numerical geometry algorithms in them, including the computation of convex hulls.
– Adrian Keister
Nov 28 at 14:07
+1 for a very interesting problem! I wonder if the convex hull would give you what you want? That would give you a piece-wise linear envelope, and there's probably some way you could get rid of the lower part of it. See en.wikipedia.org/wiki/Convex_hull_algorithms. Also, most numerical libraries would have numerical geometry algorithms in them, including the computation of convex hulls.
– Adrian Keister
Nov 28 at 14:07
Kinda disappointed that it's an interesting problem. I had hope that the answer would be 'oh that's just <mathematician's name> smoothing'
– stib
Nov 28 at 23:53
Kinda disappointed that it's an interesting problem. I had hope that the answer would be 'oh that's just <mathematician's name> smoothing'
– stib
Nov 28 at 23:53
add a comment |
1 Answer
1
active
oldest
votes
up vote
2
down vote
You're possibly looking for the envelope of the data. There is a Wikipedia article on it. https://en.m.wikipedia.org/wiki/Envelope_(waves)
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
2
down vote
You're possibly looking for the envelope of the data. There is a Wikipedia article on it. https://en.m.wikipedia.org/wiki/Envelope_(waves)
add a comment |
up vote
2
down vote
You're possibly looking for the envelope of the data. There is a Wikipedia article on it. https://en.m.wikipedia.org/wiki/Envelope_(waves)
add a comment |
up vote
2
down vote
up vote
2
down vote
You're possibly looking for the envelope of the data. There is a Wikipedia article on it. https://en.m.wikipedia.org/wiki/Envelope_(waves)
You're possibly looking for the envelope of the data. There is a Wikipedia article on it. https://en.m.wikipedia.org/wiki/Envelope_(waves)
edited Nov 26 at 2:51
answered Nov 26 at 2:18
Michael Stachowsky
1,260417
1,260417
add a comment |
add a comment |
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3013723%2fsmooth-a-graph-as-if-placing-a-rope-across-the-data%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
+1 for a very interesting problem! I wonder if the convex hull would give you what you want? That would give you a piece-wise linear envelope, and there's probably some way you could get rid of the lower part of it. See en.wikipedia.org/wiki/Convex_hull_algorithms. Also, most numerical libraries would have numerical geometry algorithms in them, including the computation of convex hulls.
– Adrian Keister
Nov 28 at 14:07
Kinda disappointed that it's an interesting problem. I had hope that the answer would be 'oh that's just <mathematician's name> smoothing'
– stib
Nov 28 at 23:53