Difference between consecutive cells?

I am new with Matlab, I want to find the difference between consecutive cells in a column from a text file and print it into a table to summarize. I want to print all the rows/cells that consecutively has 0.1 difference for 11 times. Help! Thankyou!

2 comentarios

Mariel Freo
Mariel Freo el 18 de Feb. de 2017
That is one column from a 7 column text file, "Sum1.txt"
dpb
dpb el 18 de Feb. de 2017
I massively edited the question -- use the body to ask the question; the title as a title only. That much data shouldn't be inline but as an attachment.

Iniciar sesión para comentar.

Respuestas (1)

dpb
dpb el 19 de Feb. de 2017
Start with
doc ismembertol
If you try
dx=diff(x)==0;
you'll find not many actually are identically 0 but instead are some N*eps removed owing to floating point storage not being "roundable" at precisely decimal digits of precision.

Categorías

Más información sobre Data Type Conversion en Centro de ayuda y File Exchange.

Preguntada:

el 18 de Feb. de 2017

Respondida:

dpb
el 19 de Feb. de 2017

Community Treasure Hunt

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

Start Hunting!

Translated by