Hi,
Is there a way to write these in one line of code?
mu_age=mean(age)
mn_age=min(age)
mx_age=max(age)
sigma_age=std(age)

 채택된 답변

KSSV
KSSV 2020년 12월 12일

1 개 추천

A = rand(1,10) ;
v = [min(A), max(A), mean(A), std(A)] ;
v(1) % min
v(2) % max
v(3) % mean
v(4) % std

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Dates and Time에 대해 자세히 알아보기

질문:

2020년 12월 12일

답변:

2020년 12월 12일

Community Treasure Hunt

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

Start Hunting!

Translated by