Calcdifference: Difference between revisions

From Eigenvector Research Documentation Wiki
Jump to navigation Jump to search
imported>Scott
No edit summary
imported>Bob
No edit summary
 
Line 1: Line 1:
===Purpose===
===Purpose===
Calculate difference between two datasets.
Calculate normalized difference between two datasets.


===Synopsis===
===Synopsis===
Line 8: Line 8:
===Description===
===Description===


Calculate aggregate difference in mode 1 of 2 datasets.


diffval = sqrt(sum((x1i( : )-x2i( : )).^2))./sqrt(sum(x1i( : ).^2));
Calculate normalized difference between 2 datasets (scaled to the first dataset input)
 
 
diffval = <math>\frac{\text{norm} \left(x_{1, incl}(:)-x_{2, incl}(:)\right)}{\text{norm}\left(x_{1,incl}(:)\right)}</math>
 
where the designation  <math>x_{i,incl}(:)</math> specifies that only included data (all modes) are used in the calculation.
 
====Inputs====
====Inputs====


* '''x1''' = previously generated classifier model or pred structure,
* '''x1''' = dataset to be compared to; difference is scaled relative to this response
* '''x2''' = 0 or 1. 0 indicates confusion matrix should be based on self-prediction results, 1 indicates it is based on using cross-
* '''x2''' = dataset to be compared to '''x1'''
 


====Outputs====
====Outputs====


* '''diffval''' = numeric difference value.
* '''diffval''' = normalized difference between '''x1''' and '''x2'''.
* '''diffvalstr''' = string of numeric value.
* '''diffvalstr''' = string representation of '''diffval'''.


===See Also===
===See Also===


[[caltransfer]], [[MCCTTool]]
[[caltransfer]], [[MCCTTool]]

Latest revision as of 14:16, 30 August 2017

Purpose

Calculate normalized difference between two datasets.

Synopsis

[diffval, diffvalstr] = calcdifference(x1,x2)

Description

Calculate normalized difference between 2 datasets (scaled to the first dataset input)


diffval =

where the designation specifies that only included data (all modes) are used in the calculation.

Inputs

  • x1 = dataset to be compared to; difference is scaled relative to this response
  • x2 = dataset to be compared to x1


Outputs

  • diffval = normalized difference between x1 and x2.
  • diffvalstr = string representation of diffval.

See Also

caltransfer, MCCTTool