npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

ncaa-stats

v2.0.0

Published

A package for extracting NCAA statistics

Downloads

4

Readme

ncaa-stats

  • currently supports retrieving the following types of statistics:
    • individual stats
    • team stats
    • individual game highs
    • team game highs

install

npm install ncaa-stats

use

Get sports data

var ncaa = require('ncaa-stats');

// get all available sports
ncaa.sports.getSports().then((data) => {
    console.log(data);
});

// get list of seasons for a particular sport (e.g. Men's Basketball')
ncaa.sports.getSeasons('MBB').then((data) => {
    console.log(data);
});

// get list of divisions for a particular sport and season
ncaa.sports.getDivisions({
    sport: 'MFB', // Football
    season: '2017' // The 2016-2017 season
}).then((data) => {
    console.log(data);
});

// get statistical categories and available ranking periods for a set of parameters
ncaa.sports.getSportDivisionData({
    sport: 'MFB', // Football
    season: 2016, // The season ending in 2016 (i.e. the 2015-2016 season)
    division: 11, // Division I FBS
    type: 'individual', // individual statistics
    gameHigh: false // regular statistics
}).then((data) => {
    console.log(data);
});

ncaa.sports.getSportDivisionData({
    sport: 'MFB', // Football
    season: 2016, // The 2015-2016 season
    division: 12, // Division I FCS
    type: 'team', // team statistics
    gameHigh: true // game high statistics
}).then((data) => {
    console.log(data);
});

Get individual statistics

var ncaa = require('ncaa-stats');

// get individual stats

ncaa.stats.getIndividualStats({
    sport: 'MFB', // Footbal
    division: '11', // Div I FBS
    category: '20' // All purpose yardage
        // defaults to most recent year and ranking period if none specified
}).then((data) => {
    console.log(data);
});

// get individual game highs

ncaa.stats.getIndividualGameHighs({
    sport: 'MBB', // Men's Basketball
    division: '2', // Division II
    season: '2016', // The 2015-2016 season
    category: '612' // Field Goals Made
}).then((data) => {
    console.log(data);
});

Get team statistics

var ncaa = require('ncaa-stats');

// get team statistics
ncaa.stats.getTeamStats({
    sport: 'MIH', // Men's Ice Hockey
    division: '3', // Division III
    season: '2015', // The 2014-2015 season
    category: '173' // Goal Against Average
}).then((data) => {
    console.log(data);
});

// get team game highs
ncaa.stats.getTeamGameHighs({
    sport: 'WSO', // Women's Soccer
    division: '1', // Division I
    season: '2016', // The 2015-2016 season
    category: '746' // Attendance
}).then((data) => {
    console.log(data);
});

license

MIT