How to round UP to 1 decimal value?

7 visualizaciones (últimos 30 días)
Ramadhan Hakim
Ramadhan Hakim el 23 de Oct. de 2020
Comentada: Ramadhan Hakim el 23 de Oct. de 2020
Suppose I have a value x = 6.543. I want to round it up to 6.6.
I tried
x = 6.543;
x_round = round(x,1);
But it always returns x_round=6.5
Thanks in advance!

Respuesta aceptada

Alan Stevens
Alan Stevens el 23 de Oct. de 2020
Editada: Alan Stevens el 23 de Oct. de 2020
ceil(x*10)/10

Más respuestas (0)

Categorías

Más información sobre Logical en Help Center y File Exchange.

Etiquetas

Productos

Community Treasure Hunt

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

Start Hunting!

Translated by