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

tsch-ej-numbers

v1.2.20241220

Published

API for analyzing EuroJackpot lottery numbers, trends, and probabilities.

Downloads

891

Readme

tsch-ej-numbers

Last Draw: 20.12.2024

Abstract

This is an API to analyze the EuroJackpot draws.

https://en.wikipedia.org/wiki/Eurojackpot

Use in a Demo-App

Demo-App (NextJS - Vercel)

Installation

npm install --save tsch-ej-numbers

Record Type (TRecord)

export type TRecord = {
  date: string;
  wn1: number;
  wn2: number;
  wn3: number;
  wn4: number;
  wn5: number;
  en1: number;
  en2: number;
  stake: number;
  countCl1: number;
  quotaCl1: number;
  countCl2: number;
  quotaCl2: number;
  countCl3: number;
  quotaCl3: number;
  countCl4: number;
  quotaCl4: number;
  countCl5: number;
  quotaCl5: number;
  countCl6: number;
  quotaCl6: number;
  countCl7: number;
  quotaCl7: number;
  countCl8: number;
  quotaCl8: number;
  countCl9: number;
  quotaCl9: number;
  countCl10: number;
  quotaCl10: number;
  countCl11: number;
  quotaCl11: number;
  countCl12: number;
  quotaCl12: number;
  day: string;
};

API

| Function | Version | | ---------------------- | ------- | | getRecords | 1.0.x | | getLastDraw | 1.0.x | | getFirstDraw | 1.0.x | | getClassOneDraws | 1.0.x | | getMaxJackpotDraws | 1.0.x | | getWinningNumbersCount | 1.0.x | | getEuroNumbersCount | 1.0.x | | getDecadesCount | 1.0.x | | getLowHighCount | 1.0.x | | getMinMaxQuotaCount | 1.1.x | | getTopNumbers | 1.1.x | | getFlopNumbers | 1.1.x | | getRecordByDate | 1.2.x |

API-Details

getRecords(limit)

Returns all records of available draws.

  • limit
    • optional
    • number of last records
  • return type: TRecord[]

Code:

import { getRecords } from "tsch-ej-numbers";

console.log(getRecords()); // all records
console.log(getRecords(0)); // all records
console.log(getRecords(10)); // last 10 records

getLastDraw()

Returns the last current record.

  • return type: TRecord

Code:

import { getLastDraw } from "tsch-ej-numbers";

console.log(getLastDraw());

getFirstDraw()

Returns the first record.

  • return type: TRecord

Code:

import { getFirstDraw } from "tsch-ej-numbers";

console.log(getFirstDraw());

getClassOneDraws(limit)

Returns all records with success in class one.

  • limit
    • optional
    • number of last records
  • return type: TRecord[]

Code:

import { getClassOneDraws } from "tsch-ej-numbers";

console.log(getClassOneDraws(100));

getMaxJackpotDraws(limit)

Returns all records with success in class one and a quota of 120.000.000,00 €.

  • limit
    • optional
    • number of last records
  • return type: TRecord[]

Code:

import { getMaxJackpotDraws } from "tsch-ej-numbers";

console.log(getMaxJackpotDraws());
console.log(getMaxJackpotDraws(0));
console.log(getMaxJackpotDraws(100));

getWinningNumbersCount(limit)

Returns a key / value array for all winning numbers.

  • limit
    • optional
    • number of last records
  • return type: TWinningNumbersKeyValue[]

Code:

import { getWinningNumbersCount } from "tsch-ej-numbers";

console.log(getWinningNumbersCount());
console.log(getWinningNumbersCount(0));
console.log(getWinningNumbersCount(100));

getEuroNumbersCount(limit)

Returns a key / value array for all euro numbers.

  • limit
    • optional
    • number of last records
  • return type: TEuroNumbersKeyValue[]

Code:

import { getEuroNumbersCount } from "tsch-ej-numbers";

console.log(getEuroNumbersCount());
console.log(getEuroNumbersCount(0));
console.log(getEuroNumbersCount(100));

getDecadesCount()

Returns an object for decades with according count for all draws.

  • countDecadeOne (winning numbers 1 - 10)
  • countDecadeTwo (winning numbers 11 - 20)
  • countDecadeThree (winning numbers 21 - 30)
  • countDecadeFour (winning numbers 31 - 40)
  • countDecadeFive (winning numbers 41 - 50)

Code:

import { getDecadesCount } from "tsch-ej-numbers";

console.log(getDecadesCount());

getLowHighCount()

Returns an object for low and high sections with according count for all draws.

  • countLow (winning numbers 1 - 25)
  • countHigh (winning numbers 26 - 50)

Code:

import { getLowHighCount } from "tsch-ej-numbers";

console.log(getLowHighCount());

getMinMaxQuotaCount()

Returns an object for all winning classes (1...12) with all corresponding sub-objects (min/max). These sub-objects return the date and the corresponding value for all draws.

Code:

import { getMinMaxQuotaCount } from "tsch-ej-numbers";

console.log(getMinMaxQuotaCount());

getTopNumbers()

Returns an object with key-values for top winning and euro numbers for all draws.

  • winning number (wn)
  • euro number (en)

Code:

import { getTopNumbers } from "tsch-ej-numbers";

console.log(getTopNumbers());

getFlopNumbers()

Returns an object with key-values for flop winning and euro numbers for all draws.

  • winning number (wn)
  • euro number (en)

Code:

import { getFlopNumbers } from "tsch-ej-numbers";

console.log(getFlopNumbers());

getRecordByDate()

Returns a record for a given date.

  • return type: TRecord | undefined
  • undefined >>> no record available

Code:

import { getRecordByDate } from "tsch-ej-numbers";

console.log(getRecordByDate());
console.log(getRecordByDate("31.01.2020"));
console.log(getRecordByDate("32.01.2020"));