Effacer les filtres
Effacer les filtres

find the index of the mean and mode of a plot

3 vues (au cours des 30 derniers jours)
aneps
aneps le 5 Avr 2018
Réponse apportée : dpb le 5 Avr 2018
I have a plot with X and Y values. I want to find the value of X at corresponding to the mean and mode of Y. Also, it would be good if I can make a plot with mean and mode indicated with vertical lines. How can I code it? Example data is attached.

Réponses (1)

dpb
dpb le 5 Avr 2018
doc find
NB: there's nothing that says there will be a value in the Y vector that matches the value of the mean; likelihood is there won't be far more often than is--so what then?
As for the plot(), that's a pretty simple thing to do; how about making a stab at it and show us what you've done and where you got stuck, precisely, if there is a problem.

Catégories

En savoir plus sur 2-D and 3-D Plots dans Help Center et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by