1.3.10 • Published 9 years ago

dominioneer v1.3.10

Weekly downloads
2
License
ISC
Repository
github
Last release
9 years ago

Domioneer

Dominioneer suggests dominion games based on users ratings of previous games.

Examples

Creating a game

var Dominioneer = require('dominioneer'),
	deck = new Dominioneer.Deck(null),
	builder = new Dominioneer.GameBuilder(),
	game = builder.createGame(deck, null)

Creating a game with a required set of cards

var Dominioneer = require('dominioneer'),
	builder = new Dominioneer.GameBuilder(),
	deck = new Dominioneer.Deck(null),

// Now provide a function that picks out required cards.
// The builder has one for you already.
var builder.createGame(deck, ['Cellar', 'Witch']),

Rating a game

Assuming you have created a game as, in above, its pretty easy!

// if you want to store the results permanently, history builder can
// take a reference to an AWS.dynamodb
var histories = new Dominioneer.HistoryBuilder(null);

histories.get("Dana", function (history) {
    // 0 (dislike) or 1 (liked) is allowed
	history.rate(game, 1);
});

Decide how much you will like a game

var histories = new Dominioneer.HistoryBuilder(null);

histories.get("Dana", function (history) {

	// note that prediction is asynchronous
	history.predict(game, function(rating) { console.log(rating) });
});

Installation

npm install dominioneer

Todo's

  • Improve predictions at lower sample sizes
  • Allow more variety of parameters to control random games
    • Expansion weight * Better prediction at small sample size
1.3.10

9 years ago

1.3.9

9 years ago

1.3.8

9 years ago

1.3.7

9 years ago

1.3.6

9 years ago

1.3.5

9 years ago

1.3.4

9 years ago

1.3.3

9 years ago

1.3.2

9 years ago

1.3.1

9 years ago

1.3.0

9 years ago

1.2.6

9 years ago

1.2.5

9 years ago

1.2.4

9 years ago

1.2.3

9 years ago

1.2.2

9 years ago

1.2.1

9 years ago

1.2.0

9 years ago

1.1.1

9 years ago

1.1.0

9 years ago

1.0.0

9 years ago