
Security News
AI Agent Lands PRs in Major OSS Projects, Targets Maintainers via Cold Outreach
An AI agent is merging PRs into major OSS projects and cold-emailing maintainers to drum up more work.
gl-error-bars
Advanced tools
Draws error bars around scatter points.
var shell = require('gl-now')({ clearColor: [0,0,0,0] })
var camera = require('game-shell-orbit-camera')(shell)
var createAxes = require('gl-axes')
var createErrorBars = require('gl-error-bars')
var mat4 = require('gl-mat4')
var bounds = [[-5,-5,-5], [5,5,5]]
var errorbars, axes
shell.on('gl-init', function() {
var gl = shell.gl
camera.lookAt(bounds[1], [0,0,0], [0, 1, 0])
axes = createAxes(gl, {
bounds: bounds
})
errorbars = createErrorBars(gl, {
position: [
[0,0,0],
[0,2,0],
[-2,-3,0]
],
error: [
[[-0.5,-0.5,-0.1], [0.5,0.5,0.5]],
[[0,0,0], [0.5,0.5,0.5]],
[[-0.5,-0.5,0], [0,0,0]]
],
color: [
[1,0,0],
[0,1,0],
[0,0,1]
]
})
})
shell.on('gl-render', function() {
var gl = shell.gl
gl.enable(gl.DEPTH_TEST)
var cameraParameters = {
view: camera.view(),
projection: mat4.perspective(
mat4.create(),
Math.PI/4.0,
shell.width/shell.height,
0.1,
1000.0)
}
axes.draw(cameraParameters)
errorbars.draw(cameraParameters)
})
var errorBars = require('gl-error-bars')(gl, options)Creates a new error bar object.
gl is a WebGL contextobject is a collection of properties which are used to initialize the objectReturns A new error bar object
errorBars.draw(camera)Draws the error bars
camera is an object storing the parameters to draw
camera.model is the model matrixcamera.view is the view matrixcamera.projection is the projection matrixerrorBars.update(options)Updates the error bar object
position is the position of each point in the ploterror is an array of error bounds represented as [lo,hi] for each pointcolor is either a single RGB or an array of RGB colors representing the colors of each pointlineWidth is the width of the error bar lines in pixelscapSize is the size of the cap for error barsclipBounds is a box to which all error bars will be clippederrorBars.dispose()Destroy the error bars and release all associated resources
errorBars.boundsBounds on the error bar object for display purposes
(c) 2014 Mikola Lysenko. MIT License
FAQs
Draws error bars around points
We found that gl-error-bars 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
An AI agent is merging PRs into major OSS projects and cold-emailing maintainers to drum up more work.

Research
/Security News
Chrome extension CL Suite by @CLMasters neutralizes 2FA for Facebook and Meta Business accounts while exfiltrating Business Manager contact and analytics data.

Security News
After Matplotlib rejected an AI-written PR, the agent fired back with a blog post, igniting debate over AI contributions and maintainer burden.