WOLFRAM

Enable JavaScript to interact with content and submit forms on Wolfram websites. Learn how
Wolfram Language & System Documentation Center

FeatureDistance [example1,example2,extractor]

gives the distance between example1 and example2 in the feature space defined by extractor.

FeatureDistance [extractor]

represents an operator form of FeatureDistance that can be applied to a pair of examples.

Details and Options
Details and Options Details and Options
Examples  
Basic Examples  
Options  
DistanceFunction  
See Also
Related Guides
History
Cite this Page

FeatureDistance [example1,example2,extractor]

gives the distance between example1 and example2 in the feature space defined by extractor.

FeatureDistance [extractor]

represents an operator form of FeatureDistance that can be applied to a pair of examples.

Details and Options

Examples

open all close all

Basic Examples  (1)

Construct a dataset of dog images:

Train an extractor function from this dataset:

Compute the distance in the feature space between two images using FeatureDistance :

Generate an operator form of FeatureDistance :

This operator form can be used to compute distances:

Compute the distance matrix of the dataset using this feature distance:

Find the dog that maximizes its distance from the others in the feature space:

Options  (1)

DistanceFunction  (1)

Train a feature extractor to compute term frequency-inverse document frequency vectors from texts:

Construct a feature distance for this feature extractor:

The distance function EuclideanDistance has been chosen. Use the option DistanceFunction to chose CosineDistance instead:

Wolfram Research (2016), FeatureDistance, Wolfram Language function, https://reference.wolfram.com/language/ref/FeatureDistance.html.

Text

Wolfram Research (2016), FeatureDistance, Wolfram Language function, https://reference.wolfram.com/language/ref/FeatureDistance.html.

CMS

Wolfram Language. 2016. "FeatureDistance." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/FeatureDistance.html.

APA

Wolfram Language. (2016). FeatureDistance. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/FeatureDistance.html

BibTeX

@misc{reference.wolfram_2025_featuredistance, author="Wolfram Research", title="{FeatureDistance}", year="2016", howpublished="\url{https://reference.wolfram.com/language/ref/FeatureDistance.html}", note=[Accessed: 16-November-2025]}

BibLaTeX

@online{reference.wolfram_2025_featuredistance, organization={Wolfram Research}, title={FeatureDistance}, year={2016}, url={https://reference.wolfram.com/language/ref/FeatureDistance.html}, note=[Accessed: 16-November-2025]}

Top [フレーム]

AltStyle によって変換されたページ (->オリジナル) /