How do i round to two decimals without zeros at the end

9 Ansichten (letzte 30 Tage)
Kamil Kacer
Kamil Kacer am 10 Dez. 2020
Kommentiert: Kamil Kacer am 11 Dez. 2020
Hi I just want to keed 2 decimal places without those zeros shown at the picture what do I do please I tried round

Akzeptierte Antwort

Jon
Jon am 10 Dez. 2020
Bearbeitet: Jon am 10 Dez. 2020
I think this might do what you want
fprintf('Dog detected at second %0.2f\n',idx(:))
  5 Kommentare
Rik
Rik am 10 Dez. 2020
Ah, yes, I missed that assignment. I thought the variable was not defined in the posted snippet.
Kamil Kacer
Kamil Kacer am 11 Dez. 2020
I agree i should hava assing it to some meaningfull name.
I multiplay all frames by 0.1 so I get seconds
0.1 is a step is in which window gets shiftted every iteration.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Matrices and Arrays finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by