Click here to Skip to main content
15,887,214 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Is there any way to do moving average calculations in Dataset Datatable. Is this the best option for calculating moving average calculations by using C sharp? what i am thinking is Datatable looks like excel, because of i am very familier with Excel and vba macros i think this is the best options. I am just beginer in C sharp i don't know other options, so anyone have any information about it, it will very helpful for me. And thanks in advance for your time.
Posted

Read the following links:
Do more with a DataTable and improve performance
Using DataTables More for Improving Performance

Hope you will get your idea from the above links.
 
Share this answer
 
Comments
Abhinav S 11-Dec-11 1:42am    
My 5! However, can even think about calculating the averages at query level.
Monjurul Habib 11-Dec-11 2:11am    
yes this is actually worthwhile, anyway thanks for your vote.
thatraja 11-Dec-11 7:26am    
Agree with Abhinav, 5!
Monjurul Habib 11-Dec-11 7:45am    
thank you RAJA
You could write an extension method that can be called on the datatable and does the calculations.
You don't really need to do calculations on the datatable itself.

On the other hand, it might actually be worthwhile to calculate the moving averages at the query level as well.
 
Share this answer
 
Comments
Monjurul Habib 11-Dec-11 2:10am    
my 5!
Abhinav S 11-Dec-11 2:11am    
Thank you.
thatraja 11-Dec-11 7:25am    
Right, 5!
Abhinav S 11-Dec-11 7:26am    
Thank you thatraja.
anilkeettikal 11-Dec-11 12:01pm    
Can you give an example or link how i could do it in query level?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900