New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@turf/standard-deviational-ellipse

Package Overview
Dependencies
Maintainers
4
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@turf/standard-deviational-ellipse - npm Package Compare versions

Comparing version 5.0.0 to 5.1.0

main.mjs

8

index.js

@@ -15,4 +15,7 @@ import { coordAll, featureEach } from '@turf/meta';

*
* This module was created in consultation with the following articles:
* This module mirrors the functionality of [Directional Distribution](http://desktop.arcgis.com/en/arcmap/10.3/tools/spatial-statistics-toolbox/directional-distribution.htm)
* in ArcGIS and the [QGIS Standard Deviational Ellipse Plugin](http://arken.nmbu.no/~havatv/gis/qgisplugins/SDEllipse/)
*
* **Bibliography**
*
* • Robert S. Yuill, “The Standard Deviational Ellipse; An Updated Tool for

@@ -26,3 +29,2 @@ * Spatial Description,” _Geografiska Annaler_ 53, no. 1 (1971): 28–39,

*
* It mirrors the functionality of {@link http://desktop.arcgis.com/en/arcmap/10.3/tools/spatial-statistics-toolbox/directional-distribution.htm|Directional Distribution} in ArcGIS and the {@link http://arken.nmbu.no/~havatv/gis/qgisplugins/SDEllipse/|QGIS Standard Deviational Ellipse Plugin}.
*

@@ -40,3 +42,3 @@ * @name standardDeviationalEllipse

* var points = turf.randomPoint(400, {bbox: bbox});
* var sdEllipse = turf.standardDeviationalEllipse(points, options);
* var sdEllipse = turf.standardDeviationalEllipse(points);
*

@@ -43,0 +45,0 @@ * //addToMap

@@ -19,4 +19,7 @@ 'use strict';

*
* This module was created in consultation with the following articles:
* This module mirrors the functionality of [Directional Distribution](http://desktop.arcgis.com/en/arcmap/10.3/tools/spatial-statistics-toolbox/directional-distribution.htm)
* in ArcGIS and the [QGIS Standard Deviational Ellipse Plugin](http://arken.nmbu.no/~havatv/gis/qgisplugins/SDEllipse/)
*
* **Bibliography**
*
* • Robert S. Yuill, “The Standard Deviational Ellipse; An Updated Tool for

@@ -30,3 +33,2 @@ * Spatial Description,” _Geografiska Annaler_ 53, no. 1 (1971): 28–39,

*
* It mirrors the functionality of {@link http://desktop.arcgis.com/en/arcmap/10.3/tools/spatial-statistics-toolbox/directional-distribution.htm|Directional Distribution} in ArcGIS and the {@link http://arken.nmbu.no/~havatv/gis/qgisplugins/SDEllipse/|QGIS Standard Deviational Ellipse Plugin}.
*

@@ -44,3 +46,3 @@ * @name standardDeviationalEllipse

* var points = turf.randomPoint(400, {bbox: bbox});
* var sdEllipse = turf.standardDeviationalEllipse(points, options);
* var sdEllipse = turf.standardDeviationalEllipse(points);
*

@@ -54,3 +56,3 @@ * //addToMap

options = options || {};
if (!helpers.isObject(options)) throw new Error('options is invalid');
if (!helpers.isObject(options)) { throw new Error('options is invalid'); }
var steps = options.steps || 64;

@@ -61,4 +63,4 @@ var weightTerm = options.weight;

// Validation:
if (!helpers.isNumber(steps)) throw new Error('steps must be a number');
if (!helpers.isObject(properties)) throw new Error('properties must be a number');
if (!helpers.isNumber(steps)) { throw new Error('steps must be a number'); }
if (!helpers.isObject(properties)) { throw new Error('properties must be a number'); }

@@ -65,0 +67,0 @@ // Calculate mean center & number of features:

{
"name": "@turf/standard-deviational-ellipse",
"version": "5.0.0",
"version": "5.1.0",
"description": "turf standard-deviational-ellipse module",
"main": "main",
"module": "index",
"jsnext:main": "index",
"main": "main.js",
"module": "main.mjs",
"types": "index.d.ts",

@@ -12,3 +11,4 @@ "files": [

"index.d.ts",
"main.js"
"main.js",
"main.mjs"
],

@@ -18,3 +18,4 @@ "scripts": {

"test": "node -r @std/esm test.js",
"bench": "node -r @std/esm bench.js"
"bench": "node -r @std/esm bench.js",
"docs": "node ../../scripts/generate-readmes"
},

@@ -42,7 +43,8 @@ "repository": {

"@std/esm": "*",
"@turf/random": "*",
"@turf/truncate": "*",
"@turf/random": "^5.1.0",
"@turf/truncate": "^5.1.0",
"benchmark": "*",
"load-json-file": "*",
"rollup": "*",
"rollup-plugin-buble": "*",
"tape": "*",

@@ -52,8 +54,8 @@ "write-json-file": "*"

"dependencies": {
"@turf/center-mean": "^5.0.1",
"@turf/ellipse": "^5.0.1",
"@turf/helpers": "^5.0.4",
"@turf/invariant": "^5.0.0",
"@turf/meta": "^5.0.0",
"@turf/points-within-polygon": "^5.0.0"
"@turf/center-mean": "^5.1.0",
"@turf/ellipse": "^5.1.0",
"@turf/helpers": "^5.1.0",
"@turf/invariant": "^5.1.0",
"@turf/meta": "^5.1.0",
"@turf/points-within-polygon": "^5.1.0"
},

@@ -60,0 +62,0 @@ "@std/esm": {

@@ -7,3 +7,3 @@ # @turf/standard-deviational-ellipse

Takes a [FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects) and returns a standard deviational ellipse,
Takes a [FeatureCollection](https://tools.ietf.org/html/rfc7946#section-3.3) and returns a standard deviational ellipse,
also known as a “directional distribution.” The standard deviational ellipse

@@ -14,4 +14,7 @@ aims to show the direction and the distribution of a dataset by drawing

This module was created in consultation with the following articles:
This module mirrors the functionality of [Directional Distribution](http://desktop.arcgis.com/en/arcmap/10.3/tools/spatial-statistics-toolbox/directional-distribution.htm)
in ArcGIS and the [QGIS Standard Deviational Ellipse Plugin](http://arken.nmbu.no/~havatv/gis/qgisplugins/SDEllipse/)
**Bibliography**
• Robert S. Yuill, “The Standard Deviational Ellipse; An Updated Tool for

@@ -25,7 +28,5 @@ Spatial Description,” _Geografiska Annaler_ 53, no. 1 (1971): 28–39,

It mirrors the functionality of [Directional Distribution](http://desktop.arcgis.com/en/arcmap/10.3/tools/spatial-statistics-toolbox/directional-distribution.htm) in ArcGIS and the [QGIS Standard Deviational Ellipse Plugin](http://arken.nmbu.no/~havatv/gis/qgisplugins/SDEllipse/).
**Parameters**
- `points` **[FeatureCollection](http://geojson.org/geojson-spec.html#feature-collection-objects)<[Point](http://geojson.org/geojson-spec.html#point)>** GeoJSON points
- `points` **[FeatureCollection](https://tools.ietf.org/html/rfc7946#section-3.3)<[Point](https://tools.ietf.org/html/rfc7946#section-3.1.2)>** GeoJSON points
- `options` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** Optional parameters (optional, default `{}`)

@@ -41,3 +42,3 @@ - `options.weight` **[string](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)?** the property name used to weight the center

var points = turf.randomPoint(400, {bbox: bbox});
var sdEllipse = turf.standardDeviationalEllipse(points, options);
var sdEllipse = turf.standardDeviationalEllipse(points);

@@ -48,3 +49,3 @@ //addToMap

Returns **[Feature](http://geojson.org/geojson-spec.html#feature-objects)<[Polygon](http://geojson.org/geojson-spec.html#polygon)>** an elliptical Polygon that includes approximately 1 SD of the dataset within it.
Returns **[Feature](https://tools.ietf.org/html/rfc7946#section-3.2)<[Polygon](https://tools.ietf.org/html/rfc7946#section-3.1.6)>** an elliptical Polygon that includes approximately 1 SD of the dataset within it.

@@ -51,0 +52,0 @@ <!-- This file is automatically generated. Please don't edit it directly:

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc