Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Best way to use players() function #60

Open
z-feldman opened this issue Sep 12, 2023 · 3 comments
Open

Best way to use players() function #60

z-feldman opened this issue Sep 12, 2023 · 3 comments

Comments

@z-feldman
Copy link

I'm trying to figure out how best to implement the players() function. Is this something that would go inside adjust()? An example use would be adjust predictions for NFL games with each team's starting QB. Is that even the right thinking for how the players() function works? Thanks

eheinzen added a commit that referenced this issue Sep 19, 2023
@eheinzen
Copy link
Owner

I've added a brief vignette that should help, but would be happy to answer your remaining questions! Let me know what you think.

@SamEhrlich
Copy link

I am looking to use the elo.run function to model a 5v5 game. I have a dataframe with all 10 playerids in seperate columns and a column for the outcome of the game. I am getting this error

"Error in mtfrm.default(c("99322214618656216", "99322214241694525", "101389713973624205", :
cannot mtfrm"

when attempting to input more than 2 players in the home or away team. My function currently looks like this

elo.run(home_team_win ~ players(playerid_1,playerid_2,playerid_3) +
players(playerid_6,playerid_7,playerid_8),
data = test_players_run, k = 20)

I have no problem when I only include 2 players in either home or away teams. Is there something that I can fix to allow for more than 2 players to be able to entered into the function? When looking at the vignette I see that you include other examples that use up to 7 players for games like ultimate frisbee.

@eheinzen
Copy link
Owner

eheinzen commented Oct 4, 2023

cc #61

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants