
Security News
PodRocket Podcast: Inside the Recent npm Supply Chain Attacks
Socket CEO Feross Aboukhadijeh discusses the recent npm supply chain attacks on PodRocket, covering novel attack vectors and how developers can protect themselves.
array-polar
Advanced tools
Convert array with cartesian coordinates to polar or back.
const polar = require('array-polar')
let polarCoords = polar([0,1, 1,0]) // [1,0, 1,Math.PI/2]
let cartesianCoords = polar.cartesian(coords)
Convert 2-dimensional array
with [x, y, x, y, ...]
layout to polar coordinates based on center
point, so that result is [r, θ, r, θ, ...]
array
. You may want to calculate center
as average or median of data. array
is modified in-place, so do slice if you need immutable behaviour.
Convert polar coordinates back to cartesian.
FAQs
Convert array with cartesian coordinates to polar and back
The npm package array-polar receives a total of 23 weekly downloads. As such, array-polar popularity was classified as not popular.
We found that array-polar demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket CEO Feross Aboukhadijeh discusses the recent npm supply chain attacks on PodRocket, covering novel attack vectors and how developers can protect themselves.
Security News
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
Product
Socket Firewall is a free tool that blocks malicious packages at install time, giving developers proactive protection against rising supply chain attacks.