findShortestInterval: Find the shortest interval

View source: R/findShortestInterval.R

findShortestIntervalR Documentation

Find the shortest interval

Description

This function takes a numeric vector, sorts it, and then finds the shortest interval and returns its length.

Usage

findShortestInterval(x)

Arguments

x

The numeric vector.

Value

The length of the shortest interval.

Author(s)

Gjalt-Jorn Peters

Maintainer: Gjalt-Jorn Peters ufs@opens.science

Examples


findShortestInterval(c(1, 2, 4, 7, 20, 10, 15));


ufs documentation built on Nov. 4, 2026, 1:13 a.m.