
Security News
AGENTS.md Gains Traction as an Open Format for AI Coding Agents
AGENTS.md is a fast-growing open format giving AI coding agents a shared, predictable way to understand project setup, style, and workflows.
boost_distribution is a Ruby gem to calculate various statistical properties of distributions supported by boost::math::distributions.
Before gem install
, boost headers are required. For well-known platforms, try appropriate one of the followings:
(Assumption: Most of users may use Ruby installer.) Please check whether your Ruby has been installed with devkit. If not, please re-install Ruby with devkit, which is found at the top of the page. Then, run Start Command Prompt with Ruby
from the start menu to launch the command line interface, and type following commands (each line requires hitting enter after inputs, and hit Y key when you are asked something like "install OK?"):
ridk enable
pacman -Syy
pacman -S mingw-w64-ucrt-x86_64-boost
By using setup-x86_64.exe
Cygwin GUI installer, select libboost-devel unless the headers have been installed.
$ apt-get install libboost-dev
After installation of boost headers, install the gem as:
$ gem install boost_distributions
Note that if your boost headers are not in the standard path, the following alternative are helpful for each method.
$ gem install boost_distributions -- --with-boost-include=/path/to/parent_directory_of_boost_header
Or if you want to include it into your application, add this line to Gemfile:
gem 'boost_distributions'
and execute:
$ bundle install
following
$ bundle config build.boost_distributions --with-boost-include=/path/to/parent_directory_of_boost_header
if your boost headers are in the non-standared path.
Example usage is as the followings:
require 'boost_distributions'
# Generate normal (Gaussian) distribution instance with mu = 0, sigma = 1
normal = BoostDistributions::Normal::new(0, 1)
normal.mean # => 0
normal.standard_deviation # => 1.0
normal.pdf(0) # => 0.399, Probability density function
normal.cdf(0) # => 0.5, Cumulative distribution function
normal.quantile(0.5) # => 0
List of supported distributions are:
After checking out the repo, run bundle install
to install dependencies. To install this gem onto your local machine, run bundle exec rake install
. To release a new version, update the version number in version.rb
, and then run bundle exec rake release
, which will create a git tag for the version, push git commits and the created tag, and push the .gem
file to rubygems.org.
There are some useful commands in developement life-cycle.
Command | Description |
---|---|
bundle exec rake swig | Re-generate wrapper C code |
bundle exec rake compile | compile shared library |
bundle exec rake spec | run tests |
Bug reports and pull requests are welcome on GitHub at https://github.com/fenrir-naru/ruby-boost_distributions. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the code of conduct.
Everyone interacting in the BoostDistributions project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the code of conduct.
FAQs
Unknown package
We found that boost_distributions 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
AGENTS.md is a fast-growing open format giving AI coding agents a shared, predictable way to understand project setup, style, and workflows.
Security News
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.