How do I guage plotting speed when using the plot function?

조회 수: 1 (최근 30일)
Brad . 2015년 9월 16일
댓글: Brad . 2015년 9월 23일
I'm using the plot function to produce an XY plot of altitude versus time. The total number of data points is 21,834. Using the tic and toc commands, it is taking 227 seconds to plot all of these points. This seems a bit excessive. However, in reading the MATLAB documentation, as well as several other questions regarding this topic, I'm a bit confused as to what a reasonable expectation of plot time would actually be.
Is this a reasonable amount of time given the number of data points.

채택된 답변

Mike Garrity
Mike Garrity 2015년 9월 16일
Measuring graphics performance is kind of a rich topic. There are a couple of different variables which are important to consider. I've been writing introductions to some of these on the MATLAB Graphics blog:
Perhaps one of those posts would be a good starting point for you.
  댓글 수: 3
Brad 2015년 9월 16일
It is similar and I'm looking to come up with a similar approach. Thanks again!!

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

Kirby Fears
Kirby Fears 2015년 9월 16일
편집: Kirby Fears 님. 2015년 9월 16일
Below is a simple test to show that plotting 21 thousand observations does not take long. The below plot is done in 0.005 seconds.
Are you calling the plot function repeatedly? If you show some of your code, you may get help speeding up plot performance.
  댓글 수: 5
Brad 2015년 9월 23일
Steve, thank you. This approach works great!

댓글을 달려면 로그인하십시오.


Help CenterFile Exchange에서 Data Distribution Plots에 대해 자세히 알아보기



Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by