Rx Workshop: Event Processing
- Posted: Jun 29, 2011 at 8:45 AM
- 42,700 Views
- 13 Comments
Loading User Information from Channel 9
Something went wrong getting user information from Channel 9
Loading User Information from MSDN
Something went wrong getting user information from MSDN
Loading Visual Studio Achievements
Something went wrong getting the Visual Studio Achievements
Right click “Save as…”
Learn how to use LINQ operators to filter, aggregate, and group data in observable sequences to produce desired results.
Comments have been closed since this content was published more than 30 days ago, but if you'd like to continue the conversation,
please create a new thread in our Forums,
or
Contact Us and let us know.
Follow the Discussion
Oops, something didn't work.
What does this mean?
Following an item on Channel 9 allows you to watch for new content and comments that you are interested in. You need to be signed in to Channel 9 to use this feature.What does this mean?
Following an item on Channel 9 allows you to watch for new content and comments that you are interested in and view them all on your notifications page.sign up for email notifications?
This should be a great series. Finally a reason I can push more people at work to learn Linq.
I attended SoCal Code Camp in San Diego last weekend. There was a session on real world Rx and Rx Koans. This gave me a great start on Rx. The Koans looks like a great way to help learn Rx. just wanted everyone to know about this codeplex project. The idea of using koans come from the Ruby community and are an effective way to learn.
"Koans - Zen Buddhist riddle: a Zen Buddhist riddle used to focus the mind during meditation and to develop intuitive thinking"
Hey,
This is the second video (after the introduction video) of the series, right? but I get the feeling that you're talking about things that I haven't seen in the first video (like when you said "if you did the last challenge you'll know where did that 'stock ticks' come from".) Maybe there's a problem with the ordering of the episodes.
Thanks for the great series anyway
@AbdouMoumen: This is actually the 3rd part.
@Charles:OK, thanks. The ordering of the videos in the series' page is a little confusing
what's even more confusing is that near the end of the video, when opening the solution for the challenge, the folder says "Challenge 5: Complex Event Processing" 
@AbdouMoumen: Yeah, we messed this up
It's the right challenge, though. I'll circle back with Wes and Bart to ensure we have this all right...
C
@Charles:OK, I've already downloaded the whole series though, so, I'll try to figure it out
I went through all the videos, and it this one appears to be the last one. So skip to the 3rd one in the list of videos, and come back to this one at the end.
I just noticed that the Challenge files have the correct numbers (so this is actually the 5th episode) stick to them and you'll be fine
By the way, aren't there two more episodes? ( "Reactive Coincidence" and "Programming the Cloud")
I think I got it!
Great video, where can I download the code (Chanlleng)
TIA
Yaz
All links to the challenges are giving 404 error. Could someone fix it please?
This, I believe, the answer for same task, but taking non-stocking days into account.
return from window in
(from quote in quotes
group quote by quote.Symbol
into company
from window in company.Buffer(2, 1)
from stock in this.WithNonStockingDays(window)
where stock.Symbol == "MSFT"
select stock).Buffer(5, 4)
select new {
window.Last().Date,
window.Last().Close,
AverageHigh = window.Average(q => q.High),
AverageLow = window.Average(q => q.Low)
};
private IEnumerable<StockQuote> WithNonStockingDays(IList<StockQuote> window) {
var left = window.First();
var right = window.Last();
yield return left;
while (right.Date - left.Date > TimeSpan.FromDays(1)) {
left = new StockQuote {
Close = left.Close,
Date = left.Date.AddDays(1),
High = left.High,
Low = left.Low,
Open = left.Open,
Symbol = left.Symbol,
Volume = left.Volume
};
yield return left;
}
yield return right;
}
But how do I insert code snippets?
Remove this comment
Remove this thread
close