clear
data = load('SIMAR_OR_EXT_1047047.txt');
Hs = data(:,8);


% Remove lines with 999 values
Hs(Hs == 999) = NaN;
ValidLines = find(~isnan(Hs));
Hs = Hs(ValidLines, :);

energia=length(Hs)*sum(Hs.^2);


    