Introduction to Python – Chapter 3 – Conditionals

In this video, we’ll talk about more operators you can use, conditionals, and recursion.

We’ve talked about the basic operators in the previous videos.

Operators like plus, minus, multiply, and division. A very commonly used operator is modulus or also called modulo.

What’s modulus?

Modulus works on integers and finds the remainder when dividing two numbers.

The modulus operator is the percent sign (%).

For example,

Think of dividing 7 by 3, but what gets returned is the remainder, which is 1.

Why would you need to know about the modulus operator?

The modulus operator is great for checking divisibility!

We can check if a number is an even number by using modulus.

Like:

Whenever using modulus against 2, if the remainder is 0, we know that the number is even since modulus checks for divisibility!

Any number divisible by 2 is an even number.

Let’s talk about booleans. What are boolean expressions?

booleans are the term used for True or False values.

It’s our way of telling whether a statement is True or False.

For example, we can compare two values.

5 == 5 is True

Notice that we used two equal symbols.

Two equal operators means that we want to see if the statement is True or False.

5 == 5 returns True.

In the previous video, we used one equal, but that was for assignment.

We call these types of operators, comparison operators, because we’re comparing two values.

Putting an exclamation point before the equal sign means not equal like:

5 != 5 would be False

There is support for greater than, less than, greater than or equal, and less than or equal.

6 > 5 would be True
6 < 5 would be False
6 >= 6 would be True
4 <= 4 would be True

For greater than or equal or less than or equal, the equal symbol goes after the greater than or less than sign.

Let’s talk about conditionals. What are conditionals?

Conditionals derive from the word, condition. Only do something based on a requirement.

Conditionals trigger a certain behavior based on the requirement of the boolean values, True or False.

If statements are the most used conditional. They look like English.

Which can be translated to:

x should be 6 since the if statement is True.

x is equal to 5, so we do the something, which is adding 1 to x, which makes x to 6.

x should now equal to 7. Since x was 6, it is True that x is less than 7, so we do the thing, which was add 1 to x.

You can notice that the format of the if statements always follows:

Like making a function definition, you start with the keyword. In this case, if.

Then, you space, put in the parentheses, the condition that compares values, then there’s a colon just like how defining functions works.

Most importantly, on the new lines, everything that you want the if statement to do, is tabbed once to the right, so that Python knows oh the conditional is true, do everything below the conditional that is tabbed once to the right.

The next thing that we’ll talk about are logical operators.

What are logical operators?

Logical operators is the fancy term for operators like and, or, and not for using multiple conditions or changing the condition’s meaning.

You can put and, or, and not in Python, and they have the same meaning as they do in English.

For example, think of a range of numbers. How do I check if a number is greater than 0 but less than 10? I can use the and operator! Because I need two conditions!

If I use and I can check for multiple conditions simultaneously. The conditional will be true if and only if both conditions are true.

If x was = to 11, then the condition is False since and requires both conditions to be True.

Nothing is printed out.

Let’s say that instead of wanting x to be between 0 and 10.

Let’s say that we wanted x to be outside of 0 and 10.

We can do this two ways.

First way, we can use the not operator:

By adding a simple not, we can read the condition as it would read in English.

if (x is not greater than 0 and x not less than 10)

Well, -5 is not in between the range of 0 and 10, so the conditional is true.

The other way we could trigger the conditional when x is outside of the range of 0 to 10 is with the or operator:

We read the conditional like English. If x is less than 0 or x is greater than 10, then do the statements below the conditional.

With the or operator, if either of the conditions is true, then, the statements are triggered because like how or means in English or means the same thing in Python.

Whenever you want to combine conditions in a conditional, think of the logical operators, and, or, and not, and what they can change your conditional meaning if it were English.

We’ve talked about the if statement.

When the conditional is True do something, but when False, do nothing.

What if I want to do something else when the conditional is False?

There’s something called the else statement!

Trigger different behavior when the if statement is False.

The else statement depends on an if statement. The format is as follows:

If the condition is true, do something. If the condition is not true, do something else.

Let’s say that we wanted to do something when x is an even number. And do something else when x is an odd number.

In the beginning of the video, we talked about the modulus operator that could check the remainder of a number divided by another number. Divisibility.

We can use the modulus operator with the comparison operator at the same time.

We know that if there is no remainder when x cleanly divides by 2, then x has to be even because even numbers are always divisible by 2.

But if x does not cleanly divide by 2, then we know that it has to be an odd number.

Since x is equal to 1, that means that the conditional is False, so the else statement is triggered.

When the if statement is False, do the else statement, so

1 is odd is printed out.

Let’s move on to chained conditionals, which is a fancy term for putting multiple conditionals in between the if and else statements.

Earlier in the video, we talked about the and operator for multiple conditions in the same if statement. Sometimes, you want multiple conditions for completely separate actions.

Think of a multiple choice exam. Who want’s to be a millionaire?

You have choices, A, B, C, and D.

An and operator in an if statement won’t be enough.

You need multiple if statements.

Luckily, there’s the elif statement, which is short for else if. elif allows you to use multiple if statement statements.

For example,

You can put any number of elif statements.

If two of these if statements are true, the first one will run instead.

For example,

Both if statements are true, but only the first if statement gets executed, so we see “x is greater than 0”

You can put if statements underneath if statements.
We call putting conditionals like if statements underneath other if statements nested conditionals.

Nested conditionals is a fancy term for putting conditionals underneath other conditionals.

For example,

x is positive because it’s greater than 0. Then, we encounter the if else statement underneath.

10 is cleanly divisible by 2 because it’s an even number, so x is even.

Notice how the we also tab once to the right from the relative positive underneath the if statement (x % 2 == 0)

Underneath (x % 2 == 0), we put one tab to the right from the relative position of the if statement.

Just remember that you have to put a tab underneath conditionals relative to where the conditional started.

Nested conditionals don’t always look the best way. Sometimes, instead of nested conditionals, you can use the logical operators like: and.

Our nested conditional example checks if x is greater than 0 and is even. We can put these two conditions in one line.

The main lesson that I want you to get out of conditionals is that they allow you control exactly what your program will do based on your set of requirements.

You need your program to do something based on requirements. Use conditionals.

 

Video Demonstration

Introduction to Python – Chapter 2 – Types and Functions

This video will expand on the basic concepts that we talked about in the previous video. In the first video, we talked about a terminology called assignment.

x = 5 is an assignment.

You assign values to variables. A variable can be assigned many times, and it always keeps the value of its most recent assignment.

If I do, x = 7, it replaces x = 5.

You can do x = x + 1, which adds 1 to its most recent assignment.

If we print(x), we would get 8 because 7 was its most recent assignment, and we add 1 to 7.

In the previous video, we also briefly talked about functions. We used the print() function and the type function().

A reminder of what functions are. Functions are fancy terms for defining commands that we can use in Python, and Python comes with a lot of preconfigured functions like print() and type().

When we use a specific function, it is called a function call.

When I write type(4), I am calling the function type with a value 4.

When calling a function, the value inside the parentheses is called an argument. 4 is an argument of the function.

All you need to know is that values inside the parentheses of functions are called arguments. That’s the name that they’re given.

When I print(type(4)), type(4) gives us the value, <type ‘int’>, which we print and display.

Whenever a function call gives us a value, we call it the return value.

Using the type function, we expect the function to give us back the type of the value, and if the function gives us anything back, that value given back is just called the return value.

We’ve talked a bit about types so far. Sometimes, you don’t have the type that you want.

For example, you could have a string like fruits = ” apples”

Before the word, apples, you want to put a number like 5 to get 5 apples.

We talked about how you could use the + operator to combine strings together.

However, you cannot combine an integer with a string because they’re not the same type.

Python has built-in functions that convert values from one type to another type.

There’s a function called str() that converts a value to string type. I can use str on the number 5 and add the str(5) to fruits because a string and be combined with another string.

There is a function called int() that converts a type to an integer if possible.

int parentheses with a value inside them. For example,

4 has quotation marks, so it’s a string, but since the string is also a valid number, we can convert the string into an integer with the int function
However, if we were to put a word in the int() function like int(“microwavesam”), there’s an error because int() cannot convert strings that aren’t numbers into integers.

You can also use int() with a float. A float has a decimal point value like 1.5. When you use int() with a float, every number after the decimal point is deleted. So int(1.5) is 1.

The numbers in this case, 5, are removed.

int(1.58). 58 are removed. Integers are whole numbers, so when a float is converted to an integer. There’s no rounding. The integer just deletes every number after the decimal point.

There’s a function called float() and str() for converting types to floats and strings.

float(4) becomes 4.0 because floats always have numbers after the decimal point, so an integer and whole number like 4 gets a decimal point and an automatic 0.

str(4) becomes “4” with quotation marks since strings always have a pair of quotation marks.

We’ve talked quite a bit about numeric types so far. Integers and floats.

You might be thinking why not just have a type called number and make classifying numbers easier?

Why do we have integers for exact whole numbers and floats for values with decimal point numbers? One reason is because of different behavior.

Depending on your version of Python, the division operator works differently for float and integers.

If you’re using Python 3.6 like me, you can write the expression 1 / 2 and get 0.5. Python 3.6 automatically gives the result of type float when expected.

Let’s say that you were using Python 2.7, another popular version of Python.

If I divide, 1 / 2, the result is 0 because when you divide 2 integers, you get an integer in Python 2.7 and below.

When an integer will have numbers after the decimal point, it will automatically delete every number after the decimal point.

What was supposed to be 0.5 became 0 in Python 2. Python 3 automatically converts the result to a float keeping the 0.5.

To fix this problem for Python 2, if we use 1.0 / 2.0 (two floats because we put a 0 after the decimal point), then we’ll get a float.

If you wanted to get an integer in Python 3 after dividing two integers, you can use 2 backslashes, and you’ll get 0 when you divide 1 with 2 like 1 // 2.

As we saw with division, integers and floats can have different behaviors, but they also are represented differently too.

I’m not just talking about oh, whole numbers are integers. I’m talking about inside the computer and memory. We need to explain what exactly is a float?

Floats are approximations of any number. What does that mean? For a human being, it’s easy to know that 1 / 10 is 0.1, a tenth.

Python stores floats inside memory only through 1s and 0s. The binary numbers. With binary numbers you can’t represent 0.1 exactly!

0.1 is stored as this gigantic approximation: 0.1000000000000000055511151231257827021181583404541015625
because Python can’t compute 0.1 exactly.

Many decimal point numbers like 0.1 cannot be represented exactly in the language, so we have a specific type, float, that deals with these complications.

When we print(1 / 10), Python rounds that gigantic approximation for us, so we still get 0.1 like we would expect.

We have a type, float, because numbers with decimal points aren’t exact representations, so Python separates whole numbers and decimal numbers with different types to account for their different behaviors.

Every now and then, you get strange behavior when adding two floats because of how floats are represented and stored!

To us, 0.1 + 0.2 is easy. It’s 0.3.

In Python, print(0.1 + 0.2) is 0.30000000000000004.

Next thing that we’ll talk about are imports.

Python has this thing called modules. Modules are just a fancy term for a package of preconfigured functions.

Functions like print() and type() come usable with Python, but Python doesn’t expect everyone to want all the preconfigured functions, so Python expects you to import them and specify oh I want these functions inside this module.

You can import a module by typing:

One such module is math.

We typically put imports at the top of the program.

This module comes with a bunch of preconfigured functions like sqrt().

To use a module’s functions, you type the module name, then a ., and then the function. For example,

math.sqrt(4) computes the square root of 4.

You don’t have to remember about modules and their functions.

Most of the time, I would suggest using Google to find out what a module can do.

For example, we can Google the math module and find all of its preconfigured functions.

Use Google to find out if Python has a preconfigured function for what you want to do or a module with a function.

We’ve talked a lot about these preconfigured functions that come with Python and its modules, but what about adding our own functions?

Specific commands that will do what we want them to do.

We need to define a function. Or in other words, create a function.

The layout of a function in Python goes like this.

def is short for definition.

The function definition starts from the left.

The statements below that function definition must be tabbed once to the right.

The tab is how Python knows that oh, these statements are part of the function, so if the user wants to run the function, do all the things below that are tabbed once right.

You can name the function anything that you want except the same rules for naming variables apply to naming functions.

values inside the definition of a function are called parameters.

Parameters are just another one of those fancy terms used for defining that the function expects variables inside the parentheses.

Earlier in the video we talked about arguments. When we use print(4), 4 is an argument.

However, when we’re making a function definition, the variable would be called a parameter. For example:

Let’s say that we were creating the function called print_number.

The variable, number, is called a parameter. But when we use our function, print_number(4), the 4 inside the parentheses is called an argument because we’re using the function.

The word, parameter, is used for the value in creating the function definition.

The word, argument, is used for the value in using the function.

Create a function vs use a function. Parameter vs argument.

You’ll see all of these terms often in the future, so it’s useful to understand the difference even though they can be confusing.

Whenever you’re writing the first line of a function at the end of the line, you’ll always see a colon.

Let’s make a function that uses no parameters.

Let’s say that we wanted a function, a command, that printed the first 3 letters of the alphabet each on a new line. We’ll call it alphabet

Parameters are optional. Empty parentheses means that there are no parameters.

To use the function that we created, all we have to do is type alphabet(). The same way that we would use the print() or type() function.

We can create functions that call or use other functions. Let’s say that we wanted to print the first three letters of the alphabet three times.

We can write:

When we use print_three_alphabets(), the function uses our alphabet function 3 times, and each time alphabet() function runs, it’s one by one.

The most important reason why we create our own functions is to make a program smaller by reducing repetitions!

We can have a repetitive action in a single line of Python if we create a function!

For the functions that we’ve been using like print() or type(), they only require one value. If you want to display the number, 4, you write print(4).

You can create functions with multiple parameters.

Let’s say that we wanted a function to display the number of animals a person has.

We separate each parameter with a comma.

Since I expect the user to send a number for the first parameter of the function, I’ll change that number to a string.

Earlier in the video, we said that we could convert types, adn the str() function converts the value to the string type.

Then, I’ll combine this string of the number with animal.

In the first video, we said that we could use plus with strings, and what plus with strings does is simply combine the strings.

Now, we can print the new variable we created, which is the number combined with a space and the animal name.

Let’s use the function, print_num_animals. Let’s say that we had 2 dogs.

When we use a function with multiple parameters, we separate the arguments by a comma just like how we made the definition.

The function takes the 2 arguments and uses those variables to print the number of animals.

Let’s talk about the order of execution. What’s the order of things run inside a Python script?

When you see the function definition with def, and a bunch of statements below the definition, the function won’t execute unless you USE the function.

You need to define a function and write that function definition before using it.

If I put alphabet() parentheses, trying to use it, before the function definition, I get an error that says alphabet is not defined.

In Python, statements are executed in order. Starting from line 1 to the end of the program.

Python is computed line by line in order.

If you had a lot of errors in your program, Python would look at your program, compute the first line, keep on going line by line until it finds your first error, and then stop. You’ll only see the first error message.

Then, you fix your program and run it again. Python would start at line 1 and continue until it sees the next error!

The last thing that we’ll talk about in the video is the concept of local variables. What do local variables mean?

When we declare variables we’ve seen that we can use variables the same way that we use values because the variables are equivalent to the values that we’ve assigned.

Like x = 5.

x is equivalent to 5, and we can use x in a function like print(x), and 5 would be displayed.

When variables are assigned inside a function, the variables belong to that function. The variables are local to that function.

They can not be used outside of that function. That’s where we get the term, local variable.

Let’s take a look at our print_num_animals function. We declared and assigned a variable called num_animals.

Can we use that variable? No because since the variable was declared and assigned in that function, the variable belongs to that function.

If we try to, print(num_animals) outside of the function, we get this error.

num_animals is not defined.

num_animals is local to the function where it was declared and assigned, so you have to pay attention where you make your variables.

 

Video Demonstration

Introduction to Python – Chapter 1 – Intro and Variables

Intro

Computer Science is not the study of computers nor is it only about programming. Sometimes, when people hear about Computer Science, they think oh, computers and programming!

In reality, computers are just a tool in computer science, and programming simply executes a sequence of instructions that we create.

Computer Science is all about computation, asking the question: “What exactly can be computed, how can we compute it, and how fast we can compute it?”

Computation is a fancy way of saying any type of calculation that follows rules or list of steps.

Multiplying numbers like 1 times 2 is a computation. There are rules and steps to multiplying two numbers. Likewise, adding 15 + 5 is a computation.

Computer scientists often toss the word algorithms, and that sounds fancy, but algorithms are simply the way that we solve problems.

Algorithms are just the list of steps that we use to solve any type of problem.

The rules and list of steps that apply to addition like remember to carry your 1s to the next column if the current column adds to 10 or above is an algorithm.

When you hear computations, computations are calculations that follow algorithms.

Because Computer Science dives into computations, we also think of problem solving.

“Can we solve this problem? How hard is this problem? How fast can we make the solution?”

Problem solving use computations!

The most important skill of computer science is problem solving.

Learning a programming language like Python is an excellent way to help you practice solving problems because programs are step-by-step instructions that you create in essence to solve your problems!

If algorithms are the ways or the list of steps that we use to solve problems, programming is about taking our algorithms that we have thought and planned and writing them into programming languages like Python.

The reason that we learn programming while learning Computer Science is because programming languages are languages that express computations and also solve problems for you.

Although we’ll be using Python as our language of choice in these lectures, the language is not important.

Understanding the fundamentals of programming and practicing problem solving in your own personal objectives and context is far more important.

Practice makes perfect.

 

Values, expressions, and statements

Assuming that you have Python already installed on your computer, you can save an empty file as a Python file by making sure that it has a .py extension.

Python has an IDE, integrated development environment, which serves as a program that can run a Python program. I’m using Python 3.6 in this book.

The first thing about Python that we’ll talk about are values. Values are letters or numbers that can be used in the language.

Every value has a type. Numbers like 1 and 2 have the type called: integers.

Words or sentences like “Hello world!” have the type called: strings.

Strings are enclosed in quotation marks.

The next thing that we’ll talk about are functions. Functions are fancy terms defining commands that do something in Python.

The most used function in Python is the: print function. The print function displays values on the screen.

To use print, you write, print and enclose a value inside a pair of parentheses.

You can run the program. What’s displayed is 4 and Hello world!:

You can also check the type of your value with the type function. Python has a bunch of these preconfigured functions like print() and type().

type(value) gives us the type of the value enclosed in the parentheses.

You can put functions within functions. We’ll put the type function inside the print function, so we can tell what type the 4 and “Hello world!” are.

What’s displayed is int, which is short for integer, and str, which is short for string because 4 is of type, integer, and “Hello world” is of type, string.

Variables

Now, let’s talk about variables. Variables give a name to our values. We can assign new variables with values. The variable name must be on the left side, and the values must be on the right side.

For example,

question is now the equivalent to the string, “How are you today?” because of our assignment. Likewise, x is the equivalent to 5.

The print and type functions work with variables, so we can use print and type on these variables.

What’s displayed is:

float is the type given when there is a decimal point dividing the integer and fractional part. 2 and a half has a decimal, so it’s a float type.

Variable names can use a combination of letters and numbers, and variable names are case sensitive.

When you use multiple word variable names, typically, you leave an underscore between each word like:

There are illegal characters that you cannot use in variable names like the $ symbol.

There are keywords in Python. You cannot give a variable the same name as a keyword.

For example,

There are twenty-nine keywords in Python:

You can still name variables that contain keywords, but they cannot be exactly the name of a keyword.

Like:

class is a keyword, but since it’s used inside a bigger word, the variable name is legal.

Next thing that we’ll talk about are statements. A statement is a fancy way of saying a line that executes in Python.

print(4) was a statement
x=5 was a statement

Next thing that we’ll talk about are expressions. Anything that evaluates something is called an expression.

1 + 1 is an expression.
We can print these expressions.

1 is an expression.

variables are expressions.
We can print all of those.

Next thing that we’ll talk about are operators. Operators are special symbols like addition and multiplication that perform a computation.

You can do simple math like 1 + 2.
3 * 4. The asterisk symbol is used for multiplication.
Two asterisk symbols are used for exponents. 2 ** 2.

Operators in Python follow the order of operations, which you may remember as parentheses takes priority, and then multiplication and division, and then addition and subtraction.

For instance, you can write (1 + 2) * 3, and the result would be 9 because of order of operations. 1 + 2 happens first, which equals to 3. Then, 3 is multiplied by 3 = 9.

You can use the addition operator on strings to combine strings together. For example,

The next thing we’ll talk about are comments.

When programs get more complicated, developers leave comments that are basically notes, so that you or future developers understand what you did.

Comments in Python are prefixed by the # (pound) symbol.

For example,

# (pound) symbol is used for single line comments.

For multi-line comments, where you need to include extra notes, you use a pair of triple quotation marks, one set to start the comment and one set to end the comment.

For example,

 

Video Demonstration

nba_py documentation with examples

nba_py collects nba statistics from stats.nba.com.

This page will provide documentation on the endpoints and example data that nba_py can get because nba stats api documentation is very minimal.

nba_py also does have documentation, but it’s more about the parameters of functions that you can do without examples of what return data you may get.

How to install nba_py

  1. Get pip
  2. git clone https://github.com/seemethere/nba_py
  3. cd nba_py
  4. sudo pip install .

After you install nba_py, you can use the library by including import nba_py like any other python library.

 

nba_py constants

nba_py uses a few constants for variables like CURRENT_SEASON and TEAMS.

You can find them all of these constants in the constants.py file:

https://github.com/seemethere/nba_py/blob/master/nba_py/constants.py

Using nba_py constants:

from nba_py.constants import CURRENT_SEASON
print(CURRENT_SEASON)
2016-17

Another example:

from nba_py import constants
print(constants.SeasonType.Regular)
Regular Season

 

nba_py endpoints and examples

I’m in the process of documenting every nba_py endpoint with an example.

game

For the following game related endpoints, you have to put from nba_py import game.

from nba_py import game – game.BoxscoreSummary() – endpoint: boxscoresummaryv2
game_id: "0021600457" (required),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
range_type: "0" (constants.RangeType.Default),
start_period: "0" (constants.StartPeriod.Default),
end_period: "0" (constants.EndPeriod.Default),
start_range: "0" (constants.StartRange.Default),
end_range: "0" (constants.EndRange.Default)
("0021600457", season="2016-17", season_type="Regular Season", range_type="0", start_period="0", end_period="0", start_range="0", end_range="0")

boxscore_summary.game_summary()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.game_summary())

[{
 u'LIVE_PERIOD': 4, 
 u'GAME_STATUS_ID': 3, 
 u'LIVE_PERIOD_TIME_BCAST': u'Q4 - ABC', 
 u'GAME_SEQUENCE': 2, 
 u'GAME_DATE_EST': u'2016-12-25T00:00:00', 
 u'GAME_STATUS_TEXT': u'Final', u'GAMECODE': u'20161225/GSWCLE', 
 u'LIVE_PC_TIME': u' ', 
 u'WH_STATUS': 1, 
 u'HOME_TEAM_ID': 1610612739, 
 u'VISITOR_TEAM_ID': 1610612744, 
 u'SEASON': u'2016', 
 u'GAME_ID': u'0021600457', 
 u'NATL_TV_BROADCASTER_ABBREVIATION': u'ABC'
}]

boxscore_summary.other_stats()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.other_stats())

[{
 u'LEAD_CHANGES': 5, 
 u'TOTAL_TURNOVERS': 12, 
 u'TEAM_REBOUNDS': 16, 
 u'PTS_FB': 3, 
 u'PTS_2ND_CHANCE': 17, 
 u'LEAGUE_ID': u'00', 
 u'TEAM_ABBREVIATION': u'CLE', 
 u'TIMES_TIED': 11, 
 u'TEAM_TURNOVERS': 0, 
 u'LARGEST_LEAD': 2, 
 u'TEAM_ID': 1610612739, 
 u'PTS_OFF_TO': 14, 
 u'PTS_PAINT': 44, 
 u'TEAM_CITY': u'Cleveland'
 }, 
 {
 u'LEAD_CHANGES': 4, 
 u'TOTAL_TURNOVERS': 20, 
 u'TEAM_REBOUNDS': 9, 
 u'PTS_FB': 16, 
 u'PTS_2ND_CHANCE': 8, 
 u'LEAGUE_ID': u'00', 
 u'TEAM_ABBREVIATION': u'GSW', 
 u'TIMES_TIED': 11, 
 u'TEAM_TURNOVERS': 1, 
 u'LARGEST_LEAD': 14, 
 u'TEAM_ID': 1610612744, 
 u'PTS_OFF_TO': 21, 
 u'PTS_PAINT': 50, 
 u'TEAM_CITY': u'Golden State'
}]

boxscore_summary.officials()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.officials())

[{
 u'FIRST_NAME': u'Mike', 
 u'LAST_NAME': u'Callahan', 
 u'OFFICIAL_ID': 1147, 
 u'JERSEY_NUM': u'24 '
 }, 
 {
 u'FIRST_NAME': u'Sean', 
 u'LAST_NAME': u'Corbin', 
 u'OFFICIAL_ID': 1151, 
 u'JERSEY_NUM': u'33 '
 }, 
 {
 u'FIRST_NAME': u'Matt', 
 u'LAST_NAME': u'Boland', 
 u'OFFICIAL_ID': 2005, 
 u'JERSEY_NUM': u'18 '
}]

boxscore_summary.inactive_players()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.inactive_players())

[{
 u'FIRST_NAME': u'Chris', 
 u'LAST_NAME': u'Andersen', 
 u'TEAM_ABBREVIATION': u'CLE', 
 u'TEAM_ID': 1610612739, 
 u'PLAYER_ID': 2365, 
 u'TEAM_NAME': u'Cavaliers', 
 u'JERSEY_NUM': u'00 ', 
 u'TEAM_CITY': u'Cleveland'
 },
 {u'FIRST_NAME': u'Mo', 
 u'LAST_NAME': u'Williams', 
 u'TEAM_ABBREVIATION': u'CLE', 
 u'TEAM_ID': 1610612739,
 u'PLAYER_ID': 2590, 
 u'TEAM_NAME': u'Cavaliers', 
 u'JERSEY_NUM': u'52 ', 
 u'TEAM_CITY': u'Cleveland'
 }, 
 {
 u'FIRST_NAME': u'Damian', 
 u'LAST_NAME': u'Jones', 
 u'TEAM_ABBREVIATION': u'GSW', 
 u'TEAM_ID': 1610612744, 
 u'PLAYER_ID': 1627745, 
 u'TEAM_NAME': u'Warriors', 
 u'JERSEY_NUM': u'15 ', 
 u'TEAM_CITY': u'Golden State'
 },
 {
 u'FIRST_NAME': u'James Michael', 
 u'LAST_NAME': u'McAdoo', 
 u'TEAM_ABBREVIATION': u'GSW', 
 u'TEAM_ID': 1610612744, 
 u'PLAYER_ID': 203949, 
 u'TEAM_NAME': u'Warriors', 
 u'JERSEY_NUM': u'20 ', 
 u'TEAM_CITY': u'Golden State'
}]

boxscore_summary.game_info()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.game_info())

[{
 u'GAME_DATE': u'SUNDAY, DECEMBER 25, 2016', 
 u'GAME_TIME': u'2:36', 
 u'ATTENDANCE': 20562
}]

boxscore_summary.line_score()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.line_score())

[{
 u'TEAM_CITY_NAME': u'Cleveland', 
 u'GAME_DATE_EST': u'2016-12-25T00:00:00', 
 u'PTS_OT10': 0, 
 u'TEAM_ID': 1610612739, 
 u'TEAM_WINS_LOSSES': u'23-6', 
 u'GAME_SEQUENCE': 2, 
 u'TEAM_ABBREVIATION': u'CLE', u'TEAM_NICKNAME': u'Cavaliers', 
 u'PTS_OT8': 0, 
 u'PTS_OT9': 0, 
 u'PTS_OT2': 0, 
 u'PTS_OT3': 0, 
 u'PTS_OT1': 0, 
 u'PTS_OT6': 0, 
 u'PTS_OT7': 0, 
 u'PTS_OT4': 0, 
 u'PTS_OT5': 0, 
 u'GAME_ID': u'0021600457', 
 u'PTS': 109, 
 u'PTS_QTR3': 28, 
 u'PTS_QTR2': 27, 
 u'PTS_QTR1': 25, 
 u'PTS_QTR4': 29
 }, 
 {
 u'TEAM_CITY_NAME': u'Golden State', 
 u'GAME_DATE_EST': u'2016-12-25T00:00:00', 
 u'PTS_OT10': 0, 
 u'TEAM_ID': 1610612744, 
 u'TEAM_WINS_LOSSES': u'27-5', 
 u'GAME_SEQUENCE': 2, 
 u'TEAM_ABBREVIATION': u'GSW', 
 u'TEAM_NICKNAME': u'Warriors', 
 u'PTS_OT8': 0, 
 u'PTS_OT9': 0, 
 u'PTS_OT2': 0, 
 u'PTS_OT3': 0, 
 u'PTS_OT1': 0, 
 u'PTS_OT6': 0, 
 u'PTS_OT7': 0, 
 u'PTS_OT4': 0, 
 u'PTS_OT5': 0, 
 u'GAME_ID': u'0021600457', 
 u'PTS': 108, 
 u'PTS_QTR3': 32, 
 u'PTS_QTR2': 28, 
 u'PTS_QTR1': 27, 
 u'PTS_QTR4': 21
}]

boxscore_summary.last_meeting()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.last_meeting())

[{
 u'LAST_GAME_VISITOR_TEAM_CITY1': u'GSW', 
 u'LAST_GAME_HOME_TEAM_ABBREVIATION': u'CLE', 
 u'LAST_GAME_ID': u'0041500407', 
 u'LAST_GAME_VISITOR_TEAM_ID': 1610612744, 
 u'LAST_GAME_HOME_TEAM_POINTS': 93, 
 u'LAST_GAME_HOME_TEAM_CITY': u'Cleveland', 
 u'LAST_GAME_DATE_EST': u'2016-06-19T00:00:00', 
 u'LAST_GAME_VISITOR_TEAM_NAME': u'Warriors', 
 u'LAST_GAME_HOME_TEAM_NAME': u'Cavaliers', 
 u'LAST_GAME_VISITOR_TEAM_POINTS': 89, 
 u'GAME_ID': u'0021600457', 
 u'LAST_GAME_HOME_TEAM_ID': 1610612739, 
 u'LAST_GAME_VISITOR_TEAM_CITY': u'Golden State'
}]

boxscore_summary.season_series()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.season_series())

[{
 u'SERIES_LEADER': u'Cleveland', 
 u'HOME_TEAM_ID': 1610612739, 
 u'GAME_DATE_EST': u'2016-12-25T00:00:00', 
 u'HOME_TEAM_WINS': 1, 
 u'VISITOR_TEAM_ID': 1610612744, 
 u'GAME_ID': u'0021600457', 
 u'HOME_TEAM_LOSSES': 0
}]

boxscore_summary.available_video()

boxscore_summary = game.BoxscoreSummary("0021600457")
print(boxscore_summary.available_video())

[{
 u'PT_AVAILABLE': 1, 
 u'PT_XYZ_AVAILABLE': 1, 
 u'WH_STATUS': 1, 
 u'GAME_ID': u'0021600457', 
 u'VIDEO_AVAILABLE_FLAG': 1, 
 u'HUSTLE_STATUS': 1
}]
from nba_py import game – game.Boxscore() – endpoint: boxscoretraditionalv2
game_id: "0021600457" (required),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
range_type: "0" (constants.RangeType.Default),
start_period: "0" (constants.StartPeriod.Default),
end_period: "0" (constants.EndPeriod.Default),
start_range: "0" (constants.StartRange.Default),
end_range: "0" (constants.EndRange.Default)
("0021600457", season="2016-17", season_type="Regular Season", range_type="0", start_period="0", end_period="0", start_range="0", end_range="0")

boxscore.player_stats()

boxscore = game.Boxscore("0021600457")
print(boxscore.player_stats())

[{
 u'TO': 0,
 u'MIN': u'38:10', 
 u'PLAYER_ID': 201142, 
 u'TEAM_ID': 1610612744, 
 u'REB': 15, 
 u'COMMENT': u'', 
 u'FG3A': 8, 
 u'PLAYER_NAME': u'Kevin Durant', 
 u'AST': 3, 
 u'TEAM_ABBREVIATION': u'GSW', 
 u'FG3M': 2, 
 u'OREB': 0, 
 u'FGM': 11, 
 u'START_POSITION': u'F', 
 u'PF': 2, 
 u'PTS': 36, 
 u'FGA': 23, 
 u'PLUS_MINUS': 0.0, 
 u'STL': 1, 
 u'FTA': 12, 
 u'BLK': 1, 
 u'GAME_ID': u'0021600457', 
 u'DREB': 15, 
 u'FTM': 12, 
 u'FT_PCT': 1.0, 
 u'FG_PCT': 0.478, 
 u'FG3_PCT': 0.25, 
 u'TEAM_CITY': u'Golden State'
 },...
 {
 u'TO': None,
 u'MIN': None,
 u'PLAYER_ID': 2747,
 u'TEAM_ID': 1610612739,
 u'REB': None,
 u'COMMENT': u'DND - Right Thumb Fracture ',
 u'FG3A': None,
 u'PLAYER_NAME': u'JR Smith',
 u'AST': None,
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG3M': None,
 u'OREB': None,
 u'FGM': None,
 u'START_POSITION': u'',
 u'PF': None,
 u'PTS': None,
 u'FGA': None,
 u'PLUS_MINUS': None,
 u'STL': None,
 u'FTA': None,
 u'BLK': None,
 u'GAME_ID': u'0021600457',
 u'DREB': None,
 u'FTM': None,
 u'FT_PCT': None,
 u'FG_PCT': None,
 u'FG3_PCT': None,
 u'TEAM_CITY': u'Cleveland'
}]

boxscore.team_stats()

boxscore = game.Boxscore("0021600457")
print(boxscore.team_stats())
[{
 u'TO': 19,
 u'MIN': u'240:00',
 u'TEAM_ID': 1610612744,
 u'REB': 42,
 u'TEAM_NAME': u'Warriors',
 u'FG3A': 30,
 u'AST': 25,
 u'TEAM_ABBREVIATION': u'GSW',
 u'FG3M': 9,
 u'OREB': 5,
 u'FGM': 37,
 u'PF': 24,
 u'PTS': 108,
 u'FGA': 77,
 u'PLUS_MINUS': -1.0,
 u'STL': 8,
 u'FTA': 29,
 u'BLK': 4,
 u'GAME_ID': u'0021600457',
 u'DREB': 37,
 u'FTM': 25,
 u'FT_PCT': 0.862,
 u'FG_PCT': 0.481,
 u'FG3_PCT': 0.3,
 u'TEAM_CITY': u'Golden State'
 },
 {
 u'TO': 12,
 u'MIN': u'240:00',
 u'TEAM_ID': 1610612739,
 u'REB': 44,
 u'TEAM_NAME': u'Cavaliers',
 u'FG3A': 35,
 u'AST': 20,
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG3M': 12,
 u'OREB': 18,
 u'FGM': 37,
 u'PF': 19,
 u'PTS': 109,
 u'FGA': 95,
 u'PLUS_MINUS': 1.0,
 u'STL': 14,
 u'FTA': 32,
 u'BLK': 2,
 u'GAME_ID': u'0021600457',
 u'DREB': 26,
 u'FTM': 23,
 u'FT_PCT': 0.719,
 u'FG_PCT': 0.389,
 u'FG3_PCT': 0.343,
 u'TEAM_CITY': u'Cleveland'
}]

boxscore.team_starter_bench_stats()

boxscore = game.Boxscore("0021600457")
print(boxscore.team_starter_bench_stats())

[{
 u'TO': 14,
 u'MIN': u'160:43',
 u'STARTERS_BENCH': u'Starters',
 u'TEAM_ID': 1610612744,
 u'REB': 29,
 u'TEAM_NAME': u'Warriors',
 u'FG3A': 28,
 u'AST': 12,
 u'TEAM_ABBREVIATION': u'GSW',
 u'FG3M': 9,
 u'OREB': 1,
 u'FGM': 33,
 u'PF': 16,
 u'PTS': 95,
 u'FGA': 62,
 u'STL': 6,
 u'FTA': 22,
 u'BLK': 2,
 u'GAME_ID': u'0021600457',
 u'DREB': 28,
 u'FTM': 20,
 u'FT_PCT': 0.909,
 u'FG_PCT': 0.532,
 u'FG3_PCT': 0.321,
 u'TEAM_CITY': u'Golden State'
 },
 {
 u'TO': 4,
 u'MIN': u'56:41',
 u'STARTERS_BENCH': u'Bench',
 u'TEAM_ID': 1610612744,
 u'REB': 9,
 u'TEAM_NAME': u'Warriors',
 u'FG3A': 2,
 u'AST': 12,
 u'TEAM_ABBREVIATION': u'GSW',
 u'FG3M': 0,
 u'OREB': 2,
 u'FGM': 1,
 u'PF': 5,
 u'PTS': 7,
 u'FGA': 9,
 u'STL': 1,
 u'FTA': 5,
 u'BLK': 2,
 u'GAME_ID': u'0021600457',
 u'DREB': 7,
 u'FTM': 5,
 u'FT_PCT': 1.0,
 u'FG_PCT': 0.111,
 u'FG3_PCT': 0.0,
 u'TEAM_CITY': u'Golden State'
 },
 {
 u'TO': 7,
 u'MIN': u'165:46',
 u'STARTERS_BENCH': u'Starters',
 u'TEAM_ID': 1610612739,
 u'REB': 35,
 u'TEAM_NAME': u'Cavaliers',
 u'FG3A': 20,
 u'AST': 18,
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG3M': 9,
 u'OREB': 15,
 u'FGM': 30,
 u'PF': 11,
 u'PTS': 84,
 u'FGA': 68,
 u'STL': 13,
 u'FTA': 24,
 u'BLK': 1,
 u'GAME_ID': u'0021600457',
 u'DREB': 20,
 u'FTM': 15,
 u'FT_PCT': 0.625,
 u'FG_PCT': 0.441,
 u'FG3_PCT': 0.45,
 u'TEAM_CITY': u'Cleveland'
 },
 {
 u'TO': 5,
 u'MIN': u'74:15',
 u'STARTERS_BENCH': u'Bench',
 u'TEAM_ID': 1610612739,
 u'REB': 9,
 u'TEAM_NAME': u'Cavaliers',
 u'FG3A': 15,
 u'AST': 2,
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG3M': 3,
 u'OREB': 3,
 u'FGM': 7,
 u'PF': 8,
 u'PTS': 25,
 u'FGA': 27,
 u'STL': 1,
 u'FTA': 8,
 u'BLK': 1,
 u'GAME_ID': u'0021600457',
 u'DREB': 6,
 u'FTM': 8,
 u'FT_PCT': 1.0,
 u'FG_PCT': 0.259,
 u'FG3_PCT': 0.2,
 u'TEAM_CITY': u'Cleveland'
}]
from nba_py import game – game.BoxscoreScoring() – endpoint: boxscorescoringv2
game_id: "0021600457" (required),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
range_type: "0" (constants.RangeType.Default),
start_period: "0" (constants.StartPeriod.Default),
end_period: "0" (constants.EndPeriod.Default),
start_range: "0" (constants.StartRange.Default),
end_range: "0" (constants.EndRange.Default)
("0021600457", season="2016-17", season_type="Regular Season", range_type="0", start_period="0", end_period="0", start_range="0", end_range="0")

boxscore_scoring.sql_players_scoring()

boxscore_scoring = game.BoxscoreScoring("0021600457")
print(boxscore_scoring.sql_players_scoring())

[{
 u'PCT_AST_FGM': 0.273,
 u'MIN': u'38:10',
 u'TEAM_ID': 1610612744,
 u'PCT_PTS_2PT_MR': 0.111,
 u'GAME_ID': u'0021600457',
 u'PLAYER_ID': 201142,
 u'COMMENT': u'',
 u'PLAYER_NAME': u'Kevin Durant',
 u'TEAM_ABBREVIATION': u'GSW',
 u'PCT_AST_2PM': 0.222,
 u'START_POSITION': u'F',
 u'PCT_PTS_PAINT': 0.389,
 u'PCT_UAST_2PM': 0.778,
 u'PCT_PTS_2PT': 0.5,
 u'PCT_UAST_3PM': 0.5,
 u'PCT_AST_3PM': 0.5,
 u'PCT_PTS_OFF_TOV': 0.167,
 u'PCT_PTS_FB': 0.25,
 u'PCT_UAST_FGM': 0.727,
 u'PCT_FGA_2PT': 0.652,
 u'PCT_PTS_FT': 0.333,
 u'PCT_PTS_3PT': 0.167,
 u'PCT_FGA_3PT': 0.348,
 u'TEAM_CITY': u'Golden State'
 },...
 {
 u'PCT_AST_FGM': None,
 u'MIN': None,
 u'TEAM_ID': 1610612739,
 u'PCT_PTS_2PT_MR': None,
 u'GAME_ID': u'0021600457',
 u'PLAYER_ID': 2747,
 u'COMMENT': u'DND - Right Thumb Fracture ',
 u'PLAYER_NAME': u'JR Smith',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PCT_AST_2PM': None,
 u'START_POSITION': u'',
 u'PCT_PTS_PAINT': None,
 u'PCT_UAST_2PM': None,
 u'PCT_PTS_2PT': None,
 u'PCT_UAST_3PM': None,
 u'PCT_AST_3PM': None,
 u'PCT_PTS_OFF_TOV': None,
 u'PCT_PTS_FB': None,
 u'PCT_UAST_FGM': None,
 u'PCT_FGA_2PT': None,
 u'PCT_PTS_FT': None,
 u'PCT_PTS_3PT': None,
 u'PCT_FGA_3PT': None,
 u'TEAM_CITY': u'Cleveland'
}]

boxscore_scoring.sql_team_scoring()

boxscore_scoring = game.BoxscoreScoring("0021600457")
print(boxscore_scoring.sql_team_scoring())

[{
 u'PCT_PTS_FB': 0.148,
 u'PCT_AST_FGM': 0.676,
 u'PCT_PTS_2PT': 0.519,
 u'PCT_AST_3PM': 0.889,
 u'MIN': u'240:00',
 u'PCT_UAST_2PM': 0.393,
 u'PCT_UAST_FGM': 0.324,
 u'TEAM_ABBREVIATION': u'GSW',
 u'PCT_UAST_3PM': 0.111,
 u'PCT_FGA_2PT': 0.61,
 u'PCT_PTS_PAINT': 0.463,
 u'PCT_AST_2PM': 0.607,
 u'TEAM_ID': 1610612744,
 u'PCT_PTS_2PT_MR': 0.056,
 u'PCT_PTS_FT': 0.231,
 u'GAME_ID': u'0021600457',
 u'TEAM_NAME': u'Warriors',
 u'PCT_FGA_3PT': 0.39,
 u'PCT_PTS_OFF_TOV': 0.13,
 u'PCT_PTS_3PT': 0.25,
 u'TEAM_CITY': u'Golden State'
 },
 {
 u'PCT_PTS_FB': 0.028,
 u'PCT_AST_FGM': 0.541,
 u'PCT_PTS_2PT': 0.459,
 u'PCT_AST_3PM': 0.75,
 u'MIN': u'240:00',
 u'PCT_UAST_2PM': 0.56,
 u'PCT_UAST_FGM': 0.459,
 u'TEAM_ABBREVIATION': u'CLE',
 u'PCT_UAST_3PM': 0.25,
 u'PCT_FGA_2PT': 0.632,
 u'PCT_PTS_PAINT': 0.404,
 u'PCT_AST_2PM': 0.44,
 u'TEAM_ID': 1610612739,
 u'PCT_PTS_2PT_MR': 0.055,
 u'PCT_PTS_FT': 0.211,
 u'GAME_ID': u'0021600457',
 u'TEAM_NAME': u'Cavaliers',
 u'PCT_FGA_3PT': 0.368,
 u'PCT_PTS_OFF_TOV': 0.193,
 u'PCT_PTS_3PT': 0.33,
 u'TEAM_CITY': u'Cleveland'
}]
from nba_py import game – game.BoxscoreUsage() – endpoint: boxscoreusagev2
game_id: "0021600457" (required),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
range_type: "0" (constants.RangeType.Default),
start_period: "0" (constants.StartPeriod.Default),
end_period: "0" (constants.EndPeriod.Default),
start_range: "0" (constants.StartRange.Default),
end_range: "0" (constants.EndRange.Default)
("0021600457", season="2016-17", season_type="Regular Season", range_type="0", start_period="0", end_period="0", start_range="0", end_range="0")

boxscore_usage.sql_players_usage()

boxscore_usage = game.BoxscoreUsage("0021600457")
print(boxscore_usage.sql_players_usage())
[{
 u'TEAM_ABBREVIATION': u'GSW',
 u'PCT_REB': 0.429,
 u'MIN': u'38:10',
 u'PCT_FTM': 0.6,
 u'TEAM_ID': 1610612744,
 u'GAME_ID': u'0021600457',
 u'PLAYER_ID': 201142,
 u'PCT_OREB': 0.0,
 u'PCT_FTA': 0.5,
 u'PCT_BLK': 0.5,
 u'PCT_DREB': 0.469,
 u'COMMENT': u'',
 u'PCT_FGA': 0.371,
 u'PLAYER_NAME': u'Kevin Durant',
 u'PCT_PF': 0.1,
 u'PCT_AST': 0.176,
 u'PCT_FGM': 0.379,
 u'START_POSITION': u'F',
 u'PCT_FG3A': 0.333,
 u'PCT_FG3M': 0.333,
 u'PCT_TOV': 0.0,
 u'PCT_PFD': 0.438,
 u'USG_PCT': 0.327,
 u'PCT_STL': 0.2,
 u'PCT_BLKA': 0.0,
 u'PCT_PTS': 0.429,
 u'TEAM_CITY': u'Golden State'
 },...
 {
 u'TEAM_ABBREVIATION': u'CLE',
 u'PCT_REB': None,
 u'MIN': None,
 u'PCT_FTM': None,
 u'TEAM_ID': 1610612739,
 u'GAME_ID': u'0021600457',
 u'PLAYER_ID': 2747,
 u'PCT_OREB': None,
 u'PCT_FTA': None,
 u'PCT_BLK': None,
 u'PCT_DREB': None,
 u'COMMENT': u'DND - Right Thumb Fracture ',
 u'PCT_FGA': None,
 u'PLAYER_NAME': u'JR Smith',
 u'PCT_PF': None,
 u'PCT_AST': None,
 u'PCT_FGM': None,
 u'START_POSITION': u'',
 u'PCT_FG3A': None,
 u'PCT_FG3M': None,
 u'PCT_TOV': None,
 u'PCT_PFD': None,
 u'USG_PCT': 0.0,
 u'PCT_STL': None,
 u'PCT_BLKA': None,
 u'PCT_PTS': None,
 u'TEAM_CITY': u'Cleveland'
}]

boxscore_usage.sql_team_usage()

boxscore_usage = game.BoxscoreUsage("0021600457")
print(boxscore_usage.sql_team_usage())

[{
 u'TEAM_ABBREVIATION': u'GSW',
 u'PCT_REB': 1,
 u'MIN': u'240:00',
 u'PCT_FTM': 1,
 u'TEAM_ID': 1610612744,
 u'PCT_BLK': 1,
 u'PCT_FTA': 1,
 u'TEAM_NAME': u'Warriors',
 u'PCT_DREB': 1,
 u'PCT_TOV': 1,
 u'PCT_FGA': 1,
 u'PCT_STL': 1,
 u'PCT_PF': 1,
 u'PCT_AST': 1,
 u'PCT_FGM': 1,
 u'PCT_FG3A': 1,
 u'PCT_FG3M': 1,
 u'PCT_PFD': 1,
 u'USG_PCT': 1,
 u'PCT_OREB': 1,
 u'GAME_ID': u'0021600457',
 u'PCT_BLKA': 1,
 u'PCT_PTS': 1,
 u'TEAM_CITY': u'Golden State'
 },
 {
 u'TEAM_ABBREVIATION': u'CLE',
 u'PCT_REB': 1,
 u'MIN': u'240:00',
 u'PCT_FTM': 1,
 u'TEAM_ID': 1610612739,
 u'PCT_BLK': 1,
 u'PCT_FTA': 1,
 u'TEAM_NAME': u'Cavaliers',
 u'PCT_DREB': 1,
 u'PCT_TOV': 1,
 u'PCT_FGA': 1,
 u'PCT_STL': 1,
 u'PCT_PF': 1,
 u'PCT_AST': 1,
 u'PCT_FGM': 1,
 u'PCT_FG3A': 1,
 u'PCT_FG3M': 1,
 u'PCT_PFD': 1,
 u'USG_PCT': 1,
 u'PCT_OREB': 1,
 u'GAME_ID': u'0021600457',
 u'PCT_BLKA': 1,
 u'PCT_PTS': 1,
 u'TEAM_CITY': u'Cleveland'
}]
from nba_py import game – game.BoxscoreMisc() – endpoint: boxscoremiscv2
game_id: "0021600457" (required),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
range_type: "0" (constants.RangeType.Default),
start_period: "0" (constants.StartPeriod.Default),
end_period: "0" (constants.EndPeriod.Default),
start_range: "0" (constants.StartRange.Default),
end_range: "0" (constants.EndRange.Default)
("0021600457", season="2016-17", season_type="Regular Season", range_type="0", start_period="0", end_period="0", start_range="0", end_range="0")

boxscore_misc.sql_players_misc()

boxscore_misc = game.BoxscoreMisc("0021600457")
print(boxscore_misc.sql_players_misc())

[{
 u'COMMENT': u'',
 u'PTS_OFF_TOV': 6,
 u'PF': 2,
 u'PLAYER_NAME': u'Kevin Durant',
 u'OPP_PTS_FB': 3,
 u'MIN': u'38:10',
 u'OPP_PTS_2ND_CHANCE': 11,
 u'TEAM_ABBREVIATION': u'GSW',
 u'PTS_PAINT': 14,
 u'TEAM_ID': 1610612744,
 u'START_POSITION': u'F',
 u'BLK': 1,
 u'OPP_PTS_OFF_TOV': 15,
 u'PTS_FB': 9,
 u'PLAYER_ID': 201142,
 u'GAME_ID': u'0021600457',
 u'BLKA': 0,
 u'PTS_2ND_CHANCE': 0,
 u'OPP_PTS_PAINT': 30,
 u'TEAM_CITY': u'Golden State',
 u'PFD': 7
 },...
 {
 u'COMMENT': u'DND - Right Thumb Fracture ',
 u'PTS_OFF_TOV': None,
 u'PF': None,
 u'PLAYER_NAME': u'JR Smith',
 u'OPP_PTS_FB': None,
 u'MIN': None,
 u'OPP_PTS_2ND_CHANCE': None,
 u'TEAM_ABBREVIATION': u'CLE',
 u'PTS_PAINT': None,
 u'TEAM_ID': 1610612739,
 u'START_POSITION': u'',
 u'BLK': None,
 u'OPP_PTS_OFF_TOV': None,
 u'PTS_FB': None,
 u'PLAYER_ID': 2747,
 u'GAME_ID': u'0021600457',
 u'BLKA': None,
 u'PTS_2ND_CHANCE': None,
 u'OPP_PTS_PAINT': None,
 u'TEAM_CITY': u'Cleveland',
 u'PFD': None
}]

boxscore_misc.sql_team_usage()

boxscore_usage = game.BoxscoreUsage("0021600457")
print(boxscore_usage.sql_team_usage())

[{
 u'PTS_OFF_TOV': 14.0,
 u'BLKA': 2,
 u'PTS_FB': 16.0,
 u'OPP_PTS_FB': 3.0,
 u'MIN': u'240:00',
 u'OPP_PTS_2ND_CHANCE': 17.0,
 u'TEAM_ABBREVIATION': u'GSW',
 u'TEAM_ID': 1610612744,
 u'PF': 24,
 u'BLK': 4,
 u'OPP_PTS_OFF_TOV': 21.0,
 u'PTS_PAINT': 50.0,
 u'GAME_ID': u'0021600457',
 u'TEAM_NAME': u'Warriors',
 u'PTS_2ND_CHANCE': 8.0,
 u'OPP_PTS_PAINT': 44.0,
 u'TEAM_CITY': u'Golden State',
 u'PFD': 19
 },
 {
 u'PTS_OFF_TOV': 21.0,
 u'BLKA': 4,
 u'PTS_FB': 3.0,
 u'OPP_PTS_FB': 16.0,
 u'MIN': u'240:00',
 u'OPP_PTS_2ND_CHANCE': 8.0,
 u'TEAM_ABBREVIATION': u'CLE',
 u'TEAM_ID': 1610612739,
 u'PF': 19,
 u'BLK': 2,
 u'OPP_PTS_OFF_TOV': 14.0,
 u'PTS_PAINT': 44.0,
 u'GAME_ID': u'0021600457',
 u'TEAM_NAME': u'Cavaliers',
 u'PTS_2ND_CHANCE': 17.0,
 u'OPP_PTS_PAINT': 50.0,
 u'TEAM_CITY': u'Cleveland',
 u'PFD': 24
}]
from nba_py import game – game.BoxscoreAdvanced() – endpoint: boxscoreadvancedv2
game_id: "0021600457" (required),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
range_type: "0" (constants.RangeType.Default),
start_period: "0" (constants.StartPeriod.Default),
end_period: "0" (constants.EndPeriod.Default),
start_range: "0" (constants.StartRange.Default),
end_range: "0" (constants.EndRange.Default)
("0021600457", season="2016-17", season_type="Regular Season", range_type="0", start_period="0", end_period="0", start_range="0", end_range="0")

boxscore_advanced.sql_players_advanced()

boxscore_advanced = game.BoxscoreAdvanced("0021600457")
print(boxscore_advanced.sql_players_advanced())

[{
 u'MIN': u'38:10',
 u'TEAM_ID': 1610612744,
 u'PLAYER_ID': 201142,
 u'AST_PCT': 0.167,
 u'COMMENT': u'',
 u'EFG_PCT': 0.522,
 u'PLAYER_NAME': u'Kevin Durant',
 u'DEF_RATING': 99.8,
 u'NET_RATING': 0.8,
 u'TEAM_ABBREVIATION': u'GSW',
 u'PIE': 0.328,
 u'START_POSITION': u'F',
 u'TM_TOV_PCT': 0.0,
 u'TS_PCT': 0.636,
 u'USG_PCT': 0.327,
 u'OREB_PCT': 0.0,
 u'REB_PCT': 0.217,
 u'GAME_ID': u'0021600457',
 u'DREB_PCT': 0.341,
 u'PACE': 105.49,
 u'AST_TOV': 0.0,
 u'AST_RATIO': 9.6,
 u'TEAM_CITY': u'Golden State',
 u'OFF_RATING': 100.5
 },...
 {
 u'MIN': None,
 u'TEAM_ID': 1610612739,
 u'PLAYER_ID': 2747,
 u'AST_PCT': None,
 u'COMMENT': u'DND - Right Thumb Fracture ',
 u'EFG_PCT': None,
 u'PLAYER_NAME': u'JR Smith',
 u'DEF_RATING': None,
 u'NET_RATING': None,
 u'TEAM_ABBREVIATION': u'CLE',
 u'PIE': None,
 u'START_POSITION': u'',
 u'TM_TOV_PCT': None,
 u'TS_PCT': None,
 u'USG_PCT': 0.0,
 u'OREB_PCT': None,
 u'REB_PCT': None,
 u'GAME_ID': u'0021600457',
 u'DREB_PCT': None,
 u'PACE': None,
 u'AST_TOV': None,
 u'AST_RATIO': 0.0,
 u'TEAM_CITY': u'Cleveland',
 u'OFF_RATING': None
}]

boxscore_advanced.sql_team_advanced()

boxscore_advanced = game.BoxscoreAdvanced("0021600457")
print(boxscore_advanced.sql_team_advanced())

[{ 
 u'TS_PCT': 0.602,
 u'EFG_PCT': 0.539,
 u'DEF_RATING': 105.7,
 u'MIN': u'240:00',
 u'NET_RATING': -2.7,
 u'TEAM_ABBREVIATION': u'GSW',
 u'USG_PCT': 0.198,
 u'OREB_PCT': 0.161,
 u'AST_RATIO': 18.6,
 u'PACE': 103.92,
 u'TEAM_ID': 1610612744,
 u'PIE': 0.538,
 u'REB_PCT': 0.488,
 u'DREB_PCT': 0.673,
 u'AST_TOV': 1.25,
 u'GAME_ID': u'0021600457',
 u'TEAM_NAME': u'Warriors',
 u'AST_PCT': 0.676,
 u'TM_TOV_PCT': 19.091,
 u'TEAM_CITY': u'Golden State',
 u'OFF_RATING': 103.1
 },
 {
 u'TS_PCT': 0.5,
 u'EFG_PCT': 0.453,
 u'DEF_RATING': 103.1,
 u'MIN': u'240:00',
 u'NET_RATING': 2.7,
 u'TEAM_ABBREVIATION': u'CLE',
 u'USG_PCT': 0.2,
 u'OREB_PCT': 0.327,
 u'AST_RATIO': 14.2,
 u'PACE': 103.92,
 u'TEAM_ID': 1610612739,
 u'PIE': 0.462,
 u'REB_PCT': 0.512,
 u'DREB_PCT': 0.839,
 u'AST_TOV': 1.67,
 u'GAME_ID': u'0021600457',
 u'TEAM_NAME': u'Cavaliers',
 u'AST_PCT': 0.541,
 u'TM_TOV_PCT': 11.641,
 u'TEAM_CITY': u'Cleveland',
 u'OFF_RATING': 105.7
}]
from nba_py import game – game.BoxscoreFourFactors() – endpoint: boxscorefourfactorsv2
game_id: "0021600457" (required),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
range_type: "0" (constants.RangeType.Default),
start_period: "0" (constants.StartPeriod.Default),
end_period: "0" (constants.EndPeriod.Default),
start_range: "0" (constants.StartRange.Default),
end_range: "0" (constants.EndRange.Default)
("0021600457", season="2016-17", season_type="Regular Season", range_type="0", start_period="0", end_period="0", start_range="0", end_range="0")

boxscore_four_factors.sql_players_four_factors()

boxscore_four_factors = game.BoxscoreFourFactors("0021600457")
print(boxscore_four_factors.sql_players_four_factors())

[{
 u'COMMENT': u'',
 u'EFG_PCT': 0.516,
 u'PLAYER_NAME': u'Kevin Durant',
 u'MIN': u'38:10',
 u'FTA_RATE': 0.387,
 u'TM_TOV_PCT': 0.168,
 u'TEAM_ABBREVIATION': u'GSW',
 u'OREB_PCT': 0.12,
 u'OPP_OREB_PCT': 0.273,
 u'TEAM_ID': 1610612744,
 u'START_POSITION': u'F',
 u'OPP_TOV_PCT': 0.107,
 u'OPP_EFG_PCT': 0.426,
 u'PLAYER_ID': 201142,
 u'GAME_ID': u'0021600457',
 u'OPP_FTA_RATE': 0.405,
 u'TEAM_CITY': u'Golden State'
 },...
 {
 u'COMMENT': u'DND - Right Thumb Fracture ',
 u'EFG_PCT': None,
 u'PLAYER_NAME': u'JR Smith',
 u'MIN': None,
 u'FTA_RATE': None,
 u'TM_TOV_PCT': None,
 u'TEAM_ABBREVIATION': u'CLE',
 u'OREB_PCT': None,
 u'OPP_OREB_PCT': None,
 u'TEAM_ID': 1610612739,
 u'START_POSITION': u'',
 u'OPP_TOV_PCT': None,
 u'OPP_EFG_PCT': None,
 u'PLAYER_ID': 2747,
 u'GAME_ID': u'0021600457',
 u'OPP_FTA_RATE': None,
 u'TEAM_CITY': u'Cleveland'
}]

boxscore_four_factors.sql_team_four_factors()

boxscore_four_factors = game.BoxscoreFourFactors("0021600457")
print(boxscore_four_factors.sql_team_four_factors())

[{
 u'EFG_PCT': 0.539,
 u'OPP_OREB_PCT': 0.327,
 u'MIN': u'240:00',
 u'FTA_RATE': 0.377,
 u'TM_TOV_PCT': 0.191,
 u'TEAM_ABBREVIATION': u'GSW',
 u'OREB_PCT': 0.161,
 u'TEAM_ID': 1610612744,
 u'OPP_TOV_PCT': 0.116,
 u'OPP_EFG_PCT': 0.453,
 u'GAME_ID': u'0021600457',
 u'TEAM_NAME': u'Warriors',
 u'OPP_FTA_RATE': 0.337,
 u'TEAM_CITY': u'Golden State'
 },
 {
 u'EFG_PCT': 0.453,
 u'OPP_OREB_PCT': 0.161,
 u'MIN': u'240:00',
 u'FTA_RATE': 0.337,
 u'TM_TOV_PCT': 0.116,
 u'TEAM_ABBREVIATION': u'CLE',
 u'OREB_PCT': 0.327,
 u'TEAM_ID': 1610612739,
 u'OPP_TOV_PCT': 0.191,
 u'OPP_EFG_PCT': 0.539,
 u'GAME_ID': u'0021600457',
 u'TEAM_NAME': u'Cavaliers',
 u'OPP_FTA_RATE': 0.377,
 u'TEAM_CITY': u'Cleveland'
}]
from nba_py import game – game.PlayerTracking() – endpoint: boxscoreplayertrackv2
game_id: "0021600457" (required)
("0021600457")

player_tracking.info()

player_tracking = game.PlayerTracking("0021600457")
print(player_tracking.info())

[{
 u'UFGA': 10,
 u'DFGM': 7,
 u'DIST': 2.43,
 u'DFG_PCT': 0.636,
 u'MIN': u'38:10',
 u'TCHS': 73,
 u'UFGM': 4,
 u'DFGA': 11,
 u'DRBC': 20,
 u'TEAM_ID': 1610612744,
 u'UFG_PCT': 0.4,
 u'PLAYER_ID': 201142,
 u'CFG_PCT': 0.538,
 u'COMMENT': u'',
 u'SAST': 2,
 u'PLAYER_NAME': u'Kevin Durant',
 u'AST': 3,
 u'TEAM_ABBREVIATION': u'GSW',
 u'START_POSITION': u'F',
 u'SPD': 3.81,
 u'PASS': 41,
 u'GAME_ID': u'0021600457',
 u'RBC': 21,
 u'FG_PCT': 0.478,
 u'FTAST': 1,
 u'CFGM': 7,
 u'ORBC': 1,
 u'CFGA': 13,
 u'TEAM_CITY': u'Golden State'
 },...
 {
 u'UFGA': 0,
 u'DFGM': 0,
 u'DIST': 0.0,
 u'DFG_PCT': 0.0,
 u'MIN': u'0:00',
 u'TCHS': 0,
 u'UFGM': 0,
 u'DFGA': 0,
 u'DRBC': 0,
 u'TEAM_ID': 1610612739,
 u'UFG_PCT': 0.0,
 u'PLAYER_ID': 2747,
 u'CFG_PCT': 0.0,
 u'COMMENT': u'DND - Right Thumb Fracture ',
 u'SAST': 0,
 u'PLAYER_NAME': u'JR Smith',
 u'AST': 0,
 u'TEAM_ABBREVIATION': u'CLE',
 u'START_POSITION': u'',
 u'SPD': 0.0,
 u'PASS': 0,
 u'GAME_ID': u'0021600457',
 u'RBC': 0,
 u'FG_PCT': 0.0,
 u'FTAST': 0,
 u'CFGM': 0,
 u'ORBC': 0,
 u'CFGA': 0,
 u'TEAM_CITY': u'Cleveland'
}]
from nba_py import game – game.PlayByPlay() – endpoint: playbyplay
game_id: "0021600457" (required),
season: "2016-17" (constants.CURRENT_SEASON),
start_period: "0" (constants.StartPeriod.Default),
end_period: "0" (constants.EndPeriod.Default),
start_range: "0" (constants.StartRange.Default),
end_range: "0" (constants.EndRange.Default)
("0021600457", season="2016-17", season_type="Regular Season", range_type="0", start_period="0", end_period="0", start_range="0", end_range="0")

play_by_play.info()

play_by_play = game.PlayByPlay("0021600457")
print(play_by_play.info())

[{
 u'VISITORDESCRIPTION': None,
 u'SCOREMARGIN': None,
 u'PERIOD': 1,
 u'SCORE': None,
 u'EVENTNUM': 0,
 u'NEUTRALDESCRIPTION': None,
 u'EVENTMSGACTIONTYPE': 0,
 u'HOMEDESCRIPTION': None,
 u'EVENTMSGTYPE': 12,
 u'GAME_ID': u'0021600457',
 u'WCTIMESTRING': u'2:39 PM',
 u'PCTIMESTRING': u'12:00'
 },...
 {
 u'VISITORDESCRIPTION': None,
 u'SCOREMARGIN': u'1',
 u'PERIOD': 4,
 u'SCORE': u'108 - 109',
 u'EVENTNUM': 607,
 u'NEUTRALDESCRIPTION': None,
 u'EVENTMSGACTIONTYPE': 0,
 u'HOMEDESCRIPTION': None,
 u'EVENTMSGTYPE': 13,
 u'GAME_ID': u'0021600457',
 u'WCTIMESTRING': u'5:15 PM',
 u'PCTIMESTRING': u'0:00'
}]

play_by_play.available_video()

play_by_play = game.PlayByPlay("0021600457")
print(play_by_play.available_video())

[{
 u'VIDEO_AVAILABLE_FLAG': 1
}]

 

player

For the following player related endpoints, you have to put from nba_py import player.

from nba_py import player – player.get_player()

get_player() gets a player’s player ID.

first_name: "Nene" (required),
last_name: "" (not required),
season: "2016-17" (constants.CURRENT_SEASON),
only_current: "0" (default),
just_id: True (default)

Example 1: First Name only

get_player = player.get_player("Nene")
print(get_player)

2403

Example 2: First Name – 1 word – Last Name – 1 word

first_name: "Lebron" (required),
last_name: "James" (not required),
season: "2016-17" (constants.CURRENT_SEASON),
only_current: "0" (default),
just_id: True (default)
get_player = player.get_player("Lebron", last_name="James")
print(get_player)

2544

Example 3: First Name – 1 word – Last Name – 2 words

first_name: "Metta" (required),
last_name: "World Peace" (not required),
season: "2016-17" (constants.CURRENT_SEASON),
only_current: "0" (default),
just_id: True (default)
get_player = player.get_player("Metta", last_name="World Peace")
print(get_player)

1897
from nba_py import player – player.PlayerList() – endpoint: commonallplayers
league_id: "" (required),
season: "2016-17" (constants.CURRENT_SEASON),
only_current: "1" (default)
from nba_py import player – player.PlayerSummary() – endpoint: commonplayerinfo
player_id: "2544" (required)

player_summary.info()

player_summary = player.PlayerSummary("2544")
print(player_summary.info())

[{
 u'FIRST_NAME': u'LeBron',
 u'LAST_NAME': u'James',
 u'GAMES_PLAYED_FLAG': u'Y',
 u'COUNTRY': u'USA',
 u'BIRTHDATE': u'1984-12-30T00:00:00',
 u'TEAM_ID': 1610612739,
 u'TEAM_NAME': u'Cavaliers',
 u'ROSTERSTATUS': u'Active',
 u'TEAM_ABBREVIATION': u'CLE',
 u'DISPLAY_FI_LAST': u'L. James',
 u'PLAYERCODE': u'lebron_james',
 u'DLEAGUE_FLAG': u'N',
 u'POSITION': u'Forward',
 u'FROM_YEAR': 2003,
 u'WEIGHT': u'250',
 u'DISPLAY_FIRST_LAST': u'LeBron James',
 u'HEIGHT': u'6-8',
 u'DRAFT_ROUND': u'1',
 u'TO_YEAR': 2016,
 u'DISPLAY_LAST_COMMA_FIRST': u'James,
 LeBron',
 u'DRAFT_NUMBER': u'1',
 u'TEAM_CODE': u'cavaliers',
 u'SCHOOL': u'St. Vincent-St. Mary HS (OH)',
 u'JERSEY': u'23',
 u'PERSON_ID': 2544,
 u'SEASON_EXP': 13,
 u'LAST_AFFILIATION': u'St. Vincent-St. Mary HS (OH)/USA',
 u'DRAFT_YEAR': u'2003',
 u'TEAM_CITY': u'Cleveland'
}]

player_summary.headline_stats()

player_summary = player.PlayerSummary("2544")
print(player_summary.headline_stats())

[{
 u'PLAYER_NAME': u'LeBron James',
 u'AST': 8.6,
 u'PIE': 0.181,
 u'REB': 7.9,
 u'TimeFrame': u'2016-17',
 u'PLAYER_ID': 2544,
 u'PTS': 25.4
}]
from nba_py import player – player.PlayerGeneralSplits() – endpoint: playerdashboardbygeneralsplits
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_general_splits.overall()

player_general_splits = player.PlayerGeneralSplits("2544")
print(player_general_splits.overall())

[{
 u'PF_RANK': 1,
 u'FGM_RANK': 1,
 u'FTA_RANK': 1,
 u'BLK': 0.6,
 u'MIN': 37.1,
 u'DREB_RANK': 1,
 u'TOV': 3.9,
 u'TD3': 3,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'2016-17',
 u'REB': 7.9,
 u'DD2_RANK': 1,
 u'REB_RANK': 1,
 u'CFPARAMS': u'2016-17',
 u'W_RANK': 1,
 u'FG3A': 4.9,
 u'AST': 8.6,
 u'FTM_RANK': 1,
 u'DD2': 14,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 10.5,
 u'FG3M': 1.9,
 u'OREB': 1.4,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 1,
 u'FGM': 9.4,
 u'PF': 1.6,
 u'TD3_RANK': 1,
 u'PTS': 25.4,
 u'FGA': 18.4,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 28,
 u'STL': 1.4,
 u'AST_RANK': 1,
 u'CFID': 33,
 u'L': 4,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 6.9,
 u'W': 24,
 u'W_PCT': 0.857,
 u'DREB': 6.5,
 u'FTM': 4.7,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.679,
 u'BLK_RANK': 1,
 u'PFD': 5.4,
 u'MIN_RANK': 1,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.513,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Overall',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.377,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 1,
 u'BLKA': 0.8,
 u'GP_RANK': 1,
 u'PTS_RANK': 1
}]
from nba_py import player – player.PlayerOpponentSplits() – endpoint: playerdashboardbyopponent
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_opponent_splits.by_conference()

player_opponent_splits = player.PlayerOpponentSplits("2544")
print(player_opponent_splits.by_conference())

[{ 
 u'PF_RANK': 1,
 u'FGM_RANK': 1,
 u'FTA_RANK': 2,
 u'BLK': 0.7,
 u'MIN': 37.5,
 u'DREB_RANK': 2,
 u'TOV': 3.9,
 u'TD3': 2,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'East',
 u'REB': 7.8,
 u'DD2_RANK': 1,
 u'REB_RANK': 2,
 u'CFPARAMS': u'East',
 u'W_RANK': 1,
 u'FG3A': 5.1,
 u'AST': 8.8,
 u'FTM_RANK': 2,
 u'DD2': 10,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 10.5,
 u'FG3M': 2.0,
 u'OREB': 1.3,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 1,
 u'FGM': 9.8,
 u'PF': 1.7,
 u'TD3_RANK': 1,
 u'PTS': 26.0,
 u'FGA': 19.0,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 21,
 u'STL': 1.2,
 u'AST_RANK': 1,
 u'CFID': 41,
 u'L': 3,
 u'PLUS_MINUS_RANK': 2,
 u'FTA': 6.3,
 u'W': 18,
 u'W_PCT': 0.857,
 u'DREB': 6.5,
 u'FTM': 4.4,
 u'PFD_RANK': 2,
 u'FT_PCT': 0.699,
 u'BLK_RANK': 1,
 u'PFD': 5.3,
 u'MIN_RANK': 1,
 u'OREB_RANK': 2,
 u'FG_PCT': 0.518,
 u'STL_RANK': 2,
 u'GROUP_SET': u'vs. Conference',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.38,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 2,
 u'BLKA': 0.9,
 u'GP_RANK': 1,
 u'PTS_RANK': 1
 },
 {
 u'PF_RANK': 2,
 u'FGM_RANK': 2,
 u'FTA_RANK': 1,
 u'BLK': 0.4,
 u'MIN': 35.9,
 u'DREB_RANK': 1,
 u'TOV': 4.1,
 u'TD3': 1,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'West',
 u'REB': 8.4,
 u'DD2_RANK': 2,
 u'REB_RANK': 1,
 u'CFPARAMS': u'West',
 u'W_RANK': 2,
 u'FG3A': 4.3,
 u'AST': 8.3,
 u'FTM_RANK': 1,
 u'DD2': 4,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 10.6,
 u'FG3M': 1.6,
 u'OREB': 1.7,
 u'L_RANK': 2,
 u'FT_PCT_RANK': 2,
 u'FGM': 8.3,
 u'PF': 1.6,
 u'TD3_RANK': 2,
 u'PTS': 23.6,
 u'FGA': 16.7,
 u'FG3M_RANK': 2,
 u'FGA_RANK': 2,
 u'BLKA_RANK': 2,
 u'GP': 7,
 u'STL': 1.9,
 u'AST_RANK': 2,
 u'CFID': 41,
 u'L': 1,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 8.6,
 u'W': 6,
 u'W_PCT': 0.857,
 u'DREB': 6.7,
 u'FTM': 5.4,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.633,
 u'BLK_RANK': 2,
 u'PFD': 5.9,
 u'MIN_RANK': 2,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.496,
 u'STL_RANK': 1,
 u'GROUP_SET': u'vs. Conference',
 u'FG3_PCT_RANK': 2,
 u'FG3_PCT': 0.367,
 u'FG_PCT_RANK': 2,
 u'TOV_RANK': 1,
 u'BLKA': 0.6,
 u'GP_RANK': 2,
 u'PTS_RANK': 2
}]

player_opponent_splits.by_division()

player_opponent_splits = player.PlayerOpponentSplits("2544")
print(player_opponent_splits.by_division())

[{
 u'PF_RANK': 5,
 u'FGM_RANK': 4,
 u'FTA_RANK': 4,
 u'BLK': 0.7,
 u'MIN': 36.8,
 u'DREB_RANK': 4,
 u'TOV': 4.0,
 u'TD3': 2,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'Atlantic',
 u'REB': 8.0,
 u'DD2_RANK': 1,
 u'REB_RANK': 4,
 u'CFPARAMS': u'Atlantic',
 u'W_RANK': 1,
 u'FG3A': 4.5,
 u'AST': 10.6,
 u'FTM_RANK': 2,
 u'DD2': 6,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 13.2,
 u'FG3M': 1.2,
 u'OREB': 1.7,
 u'L_RANK': 4,
 u'FT_PCT_RANK': 2,
 u'FGM': 9.1,
 u'PF': 1.6,
 u'TD3_RANK': 1,
 u'PTS': 25.0,
 u'FGA': 17.9,
 u'FG3M_RANK': 5,
 u'FGA_RANK': 5,
 u'BLKA_RANK': 1,
 u'GP': 10,
 u'STL': 1.2,
 u'AST_RANK': 2,
 u'CFID': 42,
 u'L': 0,
 u'PLUS_MINUS_RANK': 3,
 u'FTA': 7.6,
 u'W': 10,
 u'W_PCT': 1.0,
 u'DREB': 6.3,
 u'FTM': 5.6,
 u'PFD_RANK': 3,
 u'FT_PCT': 0.737,
 u'BLK_RANK': 3,
 u'PFD': 5.9,
 u'MIN_RANK': 5,
 u'OREB_RANK': 2,
 u'FG_PCT': 0.508,
 u'STL_RANK': 5,
 u'GROUP_SET': u'vs. Division',
 u'FG3_PCT_RANK': 5,
 u'FG3_PCT': 0.267,
 u'FG_PCT_RANK': 4,
 u'TOV_RANK': 3,
 u'BLKA': 1.1,
 u'GP_RANK': 1,
 u'PTS_RANK': 4
 },...
 {
 u'PF_RANK': 1,
 u'FGM_RANK': 6,
 u'FTA_RANK': 3,
 u'BLK': 0.0,
 u'MIN': 33.8,
 u'DREB_RANK': 3,
 u'TOV': 4.7,
 u'TD3': 0,
 u'FG3A_RANK': 5,
 u'GROUP_VALUE': u'Southwest',
 u'REB': 8.0,
 u'DD2_RANK': 2,
 u'REB_RANK': 5,
 u'CFPARAMS': u'Southwest',
 u'W_RANK': 3,
 u'FG3A': 4.0,
 u'AST': 9.0,
 u'FTM_RANK': 3,
 u'DD2': 2,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 18.7,
 u'FG3M': 1.0,
 u'OREB': 1.3,
 u'L_RANK': 4,
 u'FT_PCT_RANK': 3,
 u'FGM': 7.0,
 u'PF': 2.0,
 u'TD3_RANK': 3,
 u'PTS': 20.3,
 u'FGA': 14.0,
 u'FG3M_RANK': 6,
 u'FGA_RANK': 6,
 u'BLKA_RANK': 6,
 u'GP': 3,
 u'STL': 1.3,
 u'AST_RANK': 3,
 u'CFID': 42,
 u'L': 0,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 7.7,
 u'W': 3,
 u'W_PCT': 1.0,
 u'DREB': 6.7,
 u'FTM': 5.3,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.696,
 u'BLK_RANK': 6,
 u'PFD': 6.0,
 u'MIN_RANK': 6,
 u'OREB_RANK': 3,
 u'FG_PCT': 0.5,
 u'STL_RANK': 4,
 u'GROUP_SET': u'vs. Division',
 u'FG3_PCT_RANK': 6,
 u'FG3_PCT': 0.25,
 u'FG_PCT_RANK': 5,
 u'TOV_RANK': 1,
 u'BLKA': 0.0,
 u'GP_RANK': 4,
 u'PTS_RANK': 6
}]

player_opponent_splits.by_opponent()

player_opponent_splits = player.PlayerOpponentSplits("2544")
print(player_opponent_splits.by_opponent())

[{
 u'PF_RANK': 2,
 u'FGM_RANK': 14,
 u'FTA_RANK': 16,
 u'BLK': 0.0,
 u'MIN': 36.9,
 u'DREB_RANK': 7,
 u'TOV': 1.0,
 u'TD3': 0,
 u'FG3A_RANK': 7,
 u'GROUP_VALUE': u'Atlanta Hawks',
 u'REB': 9.0,
 u'DD2_RANK': 13,
 u'REB_RANK': 6,
 u'CFPARAMS': u'Atlanta Hawks',
 u'W_RANK': 18,
 u'FG3A': 5.0,
 u'AST': 5.0,
 u'FTM_RANK': 11,
 u'DD2': 0,
 u'W_PCT_RANK': 18,
 u'PLUS_MINUS': 7.0,
 u'FG3M': 2.0,
 u'OREB': 2.0,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 1,
 u'FGM': 8.0,
 u'PF': 3.0,
 u'TD3_RANK': 4,
 u'PTS': 23.0,
 u'FGA': 17.0,
 u'FG3M_RANK': 6,
 u'FGA_RANK': 13,
 u'BLKA_RANK': 8,
 u'GP': 1,
 u'STL': 3.0,
 u'AST_RANK': 17,
 u'CFID': 43,
 u'L': 1,
 u'PLUS_MINUS_RANK': 13,
 u'FTA': 5.0,
 u'W': 0,
 u'W_PCT': 0.0,
 u'DREB': 7.0,
 u'FTM': 5.0,
 u'PFD_RANK': 20,
 u'FT_PCT': 1.0,
 u'BLK_RANK': 17,
 u'PFD': 2.0,
 u'MIN_RANK': 13,
 u'OREB_RANK': 5,
 u'FG_PCT': 0.471,
 u'STL_RANK': 1,
 u'GROUP_SET': u'vs. Opponent',
 u'FG3_PCT_RANK': 6,
 u'FG3_PCT': 0.4,
 u'FG_PCT_RANK': 15,
 u'TOV_RANK': 19,
 u'BLKA': 1.0,
 u'GP_RANK': 7,
 u'PTS_RANK': 14
 },...
 {
 u'PF_RANK': 15,
 u'FGM_RANK': 9,
 u'FTA_RANK': 5,
 u'BLK': 2.0,
 u'MIN': 38.1,
 u'DREB_RANK': 2,
 u'TOV': 6.0,
 u'TD3': 0,
 u'FG3A_RANK': 11,
 u'GROUP_VALUE': u'Washington Wizards',
 u'REB': 10.0,
 u'DD2_RANK': 3,
 u'REB_RANK': 4,
 u'CFPARAMS': u'Washington Wizards',
 u'W_RANK': 7,
 u'FG3A': 4.0,
 u'AST': 5.0,
 u'FTM_RANK': 5,
 u'DD2': 1,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 7.0,
 u'FG3M': 3.0,
 u'OREB': 0.0,
 u'L_RANK': 5,
 u'FT_PCT_RANK': 8,
 u'FGM': 9.0,
 u'PF': 1.0,
 u'TD3_RANK': 4,
 u'PTS': 27.0,
 u'FGA': 18.0,
 u'FG3M_RANK': 4,
 u'FGA_RANK': 10,
 u'BLKA_RANK': 18,
 u'GP': 1,
 u'STL': 2.0,
 u'AST_RANK': 16,
 u'CFID': 43,
 u'L': 0,
 u'PLUS_MINUS_RANK': 12,
 u'FTA': 9.0,
 u'W': 1,
 u'W_PCT': 1.0,
 u'DREB': 10.0,
 u'FTM': 6.0,
 u'PFD_RANK': 3,
 u'FT_PCT': 0.667,
 u'BLK_RANK': 2,
 u'PFD': 8.0,
 u'MIN_RANK': 10,
 u'OREB_RANK': 20,
 u'FG_PCT': 0.5,
 u'STL_RANK': 7,
 u'GROUP_SET': u'vs. Opponent',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.75,
 u'FG_PCT_RANK': 11,
 u'TOV_RANK': 3,
 u'BLKA': 0.0,
 u'GP_RANK': 7,
 u'PTS_RANK': 7
}]
from nba_py import player – player.PlayerLastNGamesSplits() – endpoint: playerdashboardbylastngames
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_last_ngames_splits.by_last5()

player_last_ngames_splits = player.PlayerLastNGamesSplits("2544")
print(player_last_ngames_splits.last5())

[{ 
 u'PF_RANK': 1,
 u'FGM_RANK': 1,
 u'FTA_RANK': 1,
 u'BLK': 1.0,
 u'MIN': 38.6,
 u'DREB_RANK': 1,
 u'TOV': 3.6,
 u'TD3': 0,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'2016-17',
 u'REB': 9.4,
 u'DD2_RANK': 1,
 u'REB_RANK': 1,
 u'CFPARAMS': u'2016-17',
 u'W_RANK': 1,
 u'FG3A': 6.6,
 u'AST': 6.8,
 u'FTM_RANK': 1,
 u'DD2': 3,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 14.2,
 u'FG3M': 3.0,
 u'OREB': 2.4,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 1,
 u'FGM': 10.4,
 u'PF': 1.2,
 u'TD3_RANK': 1,
 u'PTS': 27.2,
 u'FGA': 21.0,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 5,
 u'STL': 1.4,
 u'AST_RANK': 1,
 u'CFID': 39,
 u'L': 0,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 5.4,
 u'W': 5,
 u'W_PCT': 1.0,
 u'DREB': 7.0,
 u'FTM': 3.4,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.63,
 u'BLK_RANK': 1,
 u'PFD': 4.8,
 u'MIN_RANK': 1,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.495,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Last 5 Games',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.455,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 1,
 u'BLKA': 1.0,
 u'GP_RANK': 1,
 u'PTS_RANK': 1
}]

player_last_ngames_splits.by_last10()

player_last_ngames_splits.by_last15()

player_last_ngames_splits.by_last20()

player_last_ngames_splits.gamenumber()

player_last_ngames_splits = player.PlayerLastNGamesSplits("2544")
print(player_last_ngames_splits.gamenumber())


[{
 u'PF_RANK': 1,
 u'FGM_RANK': 4,
 u'FTA_RANK': 3,
 u'BLK': 0.6,
 u'MIN': 37.0,
 u'DREB_RANK': 1,
 u'TOV': 3.7,
 u'TD3': 1,
 u'FG3A_RANK': 3,
 u'GROUP_VALUE': u'Games 1-10',
 u'REB': 8.9,
 u'DD2_RANK': 1,
 u'REB_RANK': 1,
 u'CFPARAMS': u'Games 1-10',
 u'W_RANK': 1,
 u'FG3A': 4.6,
 u'AST': 9.7,
 u'FTM_RANK': 2,
 u'DD2': 6,
 u'W_PCT_RANK': 3,
 u'PLUS_MINUS': 9.8,
 u'FG3M': 1.6,
 u'OREB': 1.3,
 u'L_RANK': 2,
 u'FT_PCT_RANK': 2,
 u'FGM': 8.5,
 u'PF': 2.0,
 u'TD3_RANK': 2,
 u'PTS': 23.4,
 u'FGA': 17.4,
 u'FG3M_RANK': 3,
 u'FGA_RANK': 3,
 u'BLKA_RANK': 1,
 u'GP': 10,
 u'STL': 1.1,
 u'AST_RANK': 2,
 u'CFID': 35,
 u'L': 1,
 u'PLUS_MINUS_RANK': 2,
 u'FTA': 6.8,
 u'W': 9,
 u'W_PCT': 0.9,
 u'DREB': 7.6,
 u'FTM': 4.8,
 u'PFD_RANK': 3,
 u'FT_PCT': 0.706,
 u'BLK_RANK': 3,
 u'PFD': 5.2,
 u'MIN_RANK': 3,
 u'OREB_RANK': 3,
 u'FG_PCT': 0.489,
 u'STL_RANK': 3,
 u'GROUP_SET': u'Game Number',
 u'FG3_PCT_RANK': 3,
 u'FG3_PCT': 0.348,
 u'FG_PCT_RANK': 4,
 u'TOV_RANK': 3,
 u'BLKA': 1.1,
 u'GP_RANK': 1,
 u'PTS_RANK': 3
 },
 {
 u'PF_RANK': 3,
 u'FGM_RANK': 3,
 u'FTA_RANK': 1,
 u'BLK': 0.3,
 u'MIN': 35.7,
 u'DREB_RANK': 4,
 u'TOV': 4.3,
 u'TD3': 2,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'Games 11-20',
 u'REB': 6.2,
 u'DD2_RANK': 2,
 u'REB_RANK': 4,
 u'CFPARAMS': u'Games 11-20',
 u'W_RANK': 3,
 u'FG3A': 4.1,
 u'AST': 8.4,
 u'FTM_RANK': 1,
 u'DD2': 4,
 u'W_PCT_RANK': 4,
 u'PLUS_MINUS': 8.8,
 u'FG3M': 1.4,
 u'OREB': 1.0,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 1,
 u'FGM': 8.9,
 u'PF': 1.4,
 u'TD3_RANK': 1,
 u'PTS': 24.6,
 u'FGA': 17.2,
 u'FG3M_RANK': 4,
 u'FGA_RANK': 4,
 u'BLKA_RANK': 4,
 u'GP': 9,
 u'STL': 1.1,
 u'AST_RANK': 3,
 u'CFID': 35,
 u'L': 3,
 u'PLUS_MINUS_RANK': 3,
 u'FTA': 7.3,
 u'W': 6,
 u'W_PCT': 0.667,
 u'DREB': 5.2,
 u'FTM': 5.3,
 u'PFD_RANK': 2,
 u'FT_PCT': 0.727,
 u'BLK_RANK': 4,
 u'PFD': 5.8,
 u'MIN_RANK': 4,
 u'OREB_RANK': 4,
 u'FG_PCT': 0.516,
 u'STL_RANK': 2,
 u'GROUP_SET': u'Game Number',
 u'FG3_PCT_RANK': 2,
 u'FG3_PCT': 0.351,
 u'FG_PCT_RANK': 2,
 u'TOV_RANK': 2,
 u'BLKA': 0.6,
 u'GP_RANK': 2,
 u'PTS_RANK': 2
 },
 {
 u'PF_RANK': 4,
 u'FGM_RANK': 1,
 u'FTA_RANK': 4,
 u'BLK': 0.6,
 u'MIN': 38.1,
 u'DREB_RANK': 2,
 u'TOV': 3.3,
 u'TD3': 0,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'Games 21-30',
 u'REB': 8.6,
 u'DD2_RANK': 3,
 u'REB_RANK': 2,
 u'CFPARAMS': u'Games 21-30',
 u'W_RANK': 2,
 u'FG3A': 6.1,
 u'AST': 7.3,
 u'FTM_RANK': 3,
 u'DD2': 3,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 14.5,
 u'FG3M': 2.6,
 u'OREB': 1.9,
 u'L_RANK': 3,
 u'FT_PCT_RANK': 3,
 u'FGM': 11.3,
 u'PF': 1.4,
 u'TD3_RANK': 3,
 u'PTS': 29.1,
 u'FGA': 21.0,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 3,
 u'GP': 8,
 u'STL': 2.1,
 u'AST_RANK': 4,
 u'CFID': 35,
 u'L': 0,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 6.5,
 u'W': 8,
 u'W_PCT': 1.0,
 u'DREB': 6.8,
 u'FTM': 4.0,
 u'PFD_RANK': 4,
 u'FT_PCT': 0.615,
 u'BLK_RANK': 2,
 u'PFD': 5.1,
 u'MIN_RANK': 2,
 u'OREB_RANK': 2,
 u'FG_PCT': 0.536,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Game Number',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.429,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 4,
 u'BLKA': 0.6,
 u'GP_RANK': 3,
 u'PTS_RANK': 1
 },
 {
 u'PF_RANK': 2,
 u'FGM_RANK': 2,
 u'FTA_RANK': 2,
 u'BLK': 3.0,
 u'MIN': 43.7,
 u'DREB_RANK': 3,
 u'TOV': 8.0,
 u'TD3': 0,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'Games 31-40',
 u'REB': 8.0,
 u'DD2_RANK': 4,
 u'REB_RANK': 3,
 u'CFPARAMS': u'Games 31-40',
 u'W_RANK': 4,
 u'FG3A': 6.0,
 u'AST': 11.0,
 u'FTM_RANK': 4,
 u'DD2': 1,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 1.0,
 u'FG3M': 2.0,
 u'OREB': 2.0,
 u'L_RANK': 3,
 u'FT_PCT_RANK': 4,
 u'FGM': 9.0,
 u'PF': 2.0,
 u'TD3_RANK': 3,
 u'PTS': 23.0,
 u'FGA': 18.0,
 u'FG3M_RANK': 2,
 u'FGA_RANK': 2,
 u'BLKA_RANK': 2,
 u'GP': 1,
 u'STL': 1.0,
 u'AST_RANK': 1,
 u'CFID': 35,
 u'L': 0,
 u'PLUS_MINUS_RANK': 4,
 u'FTA': 7.0,
 u'W': 1,
 u'W_PCT': 1.0,
 u'DREB': 6.0,
 u'FTM': 3.0,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.429,
 u'BLK_RANK': 1,
 u'PFD': 7.0,
 u'MIN_RANK': 1,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.5,
 u'STL_RANK': 4,
 u'GROUP_SET': u'Game Number',
 u'FG3_PCT_RANK': 4,
 u'FG3_PCT': 0.333,
 u'FG_PCT_RANK': 3,
 u'TOV_RANK': 1,
 u'BLKA': 1.0,
 u'GP_RANK': 4,
 u'PTS_RANK': 4
}]
from nba_py import player – player.PlayerInGameSplits() – endpoint: playerdashboardbygamesplits
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_game_splits.by_half()

player_game_splits = player.PlayerInGameSplits("2544")
print(player_game_splits.by_half())

[{
 u'PF_RANK': 3,
 u'FGM_RANK': 2,
 u'FTA_RANK': 2,
 u'BLK': 0.2,
 u'MIN': 18.9,
 u'DREB_RANK': 2,
 u'TOV': 2.0,
 u'TD3': 3,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'First Half',
 u'REB': 4.3,
 u'DD2_RANK': 1,
 u'REB_RANK': 2,
 u'CFPARAMS': u'First Half',
 u'W_RANK': 1,
 u'FG3A': 1.9,
 u'AST': 5.0,
 u'FTM_RANK': 1,
 u'DD2': 14,
 u'W_PCT_RANK': 2,
 u'PLUS_MINUS': 7.3,
 u'FG3M': 0.6,
 u'OREB': 0.7,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 2,
 u'FGM': 4.6,
 u'PF': 0.5,
 u'TD3_RANK': 1,
 u'PTS': 12.0,
 u'FGA': 8.8,
 u'FG3M_RANK': 3,
 u'FGA_RANK': 2,
 u'BLKA_RANK': 2,
 u'GP': 28,
 u'STL': 0.8,
 u'AST_RANK': 1,
 u'CFID': 24,
 u'L': 4,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 3.3,
 u'W': 24,
 u'W_PCT': 0.857,
 u'DREB': 3.6,
 u'FTM': 2.3,
 u'PFD_RANK': 2,
 u'FT_PCT': 0.707,
 u'BLK_RANK': 2,
 u'PFD': 2.5,
 u'MIN_RANK': 1,
 u'OREB_RANK': 2,
 u'FG_PCT': 0.518,
 u'STL_RANK': 1,
 u'GROUP_SET': u'By Half',
 u'FG3_PCT_RANK': 3,
 u'FG3_PCT': 0.296,
 u'FG_PCT_RANK': 2,
 u'TOV_RANK': 1,
 u'BLKA': 0.4,
 u'GP_RANK': 1,
 u'PTS_RANK': 2
 },
 {
 u'PF_RANK': 1,
 u'FGM_RANK': 1,
 u'FTA_RANK': 1,
 u'BLK': 0.4,
 u'MIN': 18.0,
 u'DREB_RANK': 3,
 u'TOV': 1.9,
 u'TD3': 3,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'Second Half',
 u'REB': 3.5,
 u'DD2_RANK': 1,
 u'REB_RANK': 3,
 u'CFPARAMS': u'Second Half',
 u'W_RANK': 1,
 u'FG3A': 3.0,
 u'AST': 3.6,
 u'FTM_RANK': 2,
 u'DD2': 14,
 u'W_PCT_RANK': 2,
 u'PLUS_MINUS': 3.0,
 u'FG3M': 1.3,
 u'OREB': 0.7,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 3,
 u'FGM': 4.8,
 u'PF': 1.1,
 u'TD3_RANK': 1,
 u'PTS': 13.1,
 u'FGA': 9.5,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 28,
 u'STL': 0.6,
 u'AST_RANK': 2,
 u'CFID': 24,
 u'L': 4,
 u'PLUS_MINUS_RANK': 3,
 u'FTA': 3.5,
 u'W': 24,
 u'W_PCT': 0.857,
 u'DREB': 2.8,
 u'FTM': 2.3,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.646,
 u'BLK_RANK': 1,
 u'PFD': 2.9,
 u'MIN_RANK': 2,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.504,
 u'STL_RANK': 2,
 u'GROUP_SET': u'By Half',
 u'FG3_PCT_RANK': 2,
 u'FG3_PCT': 0.422,
 u'FG_PCT_RANK': 3,
 u'TOV_RANK': 2,
 u'BLKA': 0.4,
 u'GP_RANK': 1,
 u'PTS_RANK': 1
 
 },
 {
 u'PF_RANK': 2,
 u'FGM_RANK': 3,
 u'FTA_RANK': 3,
 u'BLK': 0.0,
 u'MIN': 5.0,
 u'DREB_RANK': 1,
 u'TOV': 0.0,
 u'TD3': 0,
 u'FG3A_RANK': 3,
 u'GROUP_VALUE': u'Overtime',
 u'REB': 5.0,
 u'DD2_RANK': 3,
 u'REB_RANK': 1,
 u'CFPARAMS': u'Overtime',
 u'W_RANK': 3,
 u'FG3A': 1.0,
 u'AST': 1.0,
 u'FTM_RANK': 3,
 u'DD2': 1,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 6.0,
 u'FG3M': 1.0,
 u'OREB': 0.0,
 u'L_RANK': 3,
 u'FT_PCT_RANK': 1,
 u'FGM': 2.0,
 u'PF': 1.0,
 u'TD3_RANK': 3,
 u'PTS': 7.0,
 u'FGA': 2.0,
 u'FG3M_RANK': 2,
 u'FGA_RANK': 3,
 u'BLKA_RANK': 3,
 u'GP': 1,
 u'STL': 0.0,
 u'AST_RANK': 3,
 u'CFID': 24,
 u'L': 0,
 u'PLUS_MINUS_RANK': 2,
 u'FTA': 2.0,
 u'W': 1,
 u'W_PCT': 1.0,
 u'DREB': 5.0,
 u'FTM': 2.0,
 u'PFD_RANK': 3,
 u'FT_PCT': 1.0,
 u'BLK_RANK': 3,
 u'PFD': 2.0,
 u'MIN_RANK': 3,
 u'OREB_RANK': 3,
 u'FG_PCT': 1.0,
 u'STL_RANK': 3,
 u'GROUP_SET': u'By Half',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 1.0,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 3,
 u'BLKA': 0.0,
 u'GP_RANK': 3,
 u'PTS_RANK': 3
}]

player_game_splits.by_period()

player_game_splits = player.PlayerInGameSplits("2544")
print(player_game_splits.by_period())

[{
 u'PF_RANK': 5,
 u'FGM_RANK': 4,
 u'FTA_RANK': 5,
 u'BLK': 0.0,
 u'MIN': 9.7,
 u'DREB_RANK': 4,
 u'TOV': 1.0,
 u'TD3': 3,
 u'FG3A_RANK': 5,
 u'GROUP_VALUE': 1,
 u'REB': 2.0,
 u'DD2_RANK': 1,
 u'REB_RANK': 4,
 u'CFPARAMS': u'1',
 u'W_RANK': 1,
 u'FG3A': 0.6,
 u'AST': 2.9,
 u'FTM_RANK': 5,
 u'DD2': 14,
 u'W_PCT_RANK': 3,
 u'PLUS_MINUS': 6.0,
 u'FG3M': 0.2,
 u'OREB': 0.2,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 2,
 u'FGM': 2.2,
 u'PF': 0.1,
 u'TD3_RANK': 1,
 u'PTS': 5.4,
 u'FGA': 4.0,
 u'FG3M_RANK': 5,
 u'FGA_RANK': 4,
 u'BLKA_RANK': 2,
 u'GP': 28,
 u'STL': 0.5,
 u'AST_RANK': 1,
 u'CFID': 25,
 u'L': 4,
 u'PLUS_MINUS_RANK': 2,
 u'FTA': 1.2,
 u'W': 24,
 u'W_PCT': 0.857,
 u'DREB': 1.8,
 u'FTM': 0.9,
 u'PFD_RANK': 5,
 u'FT_PCT': 0.727,
 u'BLK_RANK': 4,
 u'PFD': 0.9,
 u'MIN_RANK': 2,
 u'OREB_RANK': 4,
 u'FG_PCT': 0.54,
 u'STL_RANK': 2,
 u'GROUP_SET': u'By Period',
 u'FG3_PCT_RANK': 4,
 u'FG3_PCT': 0.375,
 u'FG_PCT_RANK': 2,
 u'TOV_RANK': 3,
 u'BLKA': 0.2,
 u'GP_RANK': 1,
 u'PTS_RANK': 5
 },...
 {
 u'PF_RANK': 1,
 u'FGM_RANK': 5,
 u'FTA_RANK': 3,
 u'BLK': 0.0,
 u'MIN': 5.0,
 u'DREB_RANK': 1,
 u'TOV': 0.0,
 u'TD3': 0,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': 5,
 u'REB': 5.0,
 u'DD2_RANK': 5,
 u'REB_RANK': 1,
 u'CFPARAMS': u'5',
 u'W_RANK': 5,
 u'FG3A': 1.0,
 u'AST': 1.0,
 u'FTM_RANK': 1,
 u'DD2': 1,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 6.0,
 u'FG3M': 1.0,
 u'OREB': 0.0,
 u'L_RANK': 5,
 u'FT_PCT_RANK': 1,
 u'FGM': 2.0,
 u'PF': 1.0,
 u'TD3_RANK': 5,
 u'PTS': 7.0,
 u'FGA': 2.0,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 5,
 u'BLKA_RANK': 5,
 u'GP': 1,
 u'STL': 0.0,
 u'AST_RANK': 5,
 u'CFID': 25,
 u'L': 0,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 2.0,
 u'W': 1,
 u'W_PCT': 1.0,
 u'DREB': 5.0,
 u'FTM': 2.0,
 u'PFD_RANK': 1,
 u'FT_PCT': 1.0,
 u'BLK_RANK': 5,
 u'PFD': 2.0,
 u'MIN_RANK': 5,
 u'OREB_RANK': 5,
 u'FG_PCT': 1.0,
 u'STL_RANK': 5,
 u'GROUP_SET': u'By Period',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 1.0,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 5,
 u'BLKA': 0.0,
 u'GP_RANK': 5,
 u'PTS_RANK': 2
}]

player_game_splits.by_score_margin()

player_game_splits = player.PlayerInGameSplits("2544")
print(player_game_splits.by_score_margin())

[{
 u'PF_RANK': 6,
 u'FGM_RANK': 6,
 u'FTA_RANK': 6,
 u'BLK': 0.0,
 u'MIN': 2.0,
 u'DREB_RANK': 6,
 u'TOV': 0.2,
 u'TD3': 3,
 u'FG3A_RANK': 6,
 u'GROUP_VALUE': u'Tied',
 u'REB': 0.3,
 u'DD2_RANK': 1,
 u'REB_RANK': 6,
 u'CFPARAMS': u'Tied',
 u'W_RANK': 1,
 u'FG3A': 0.1,
 u'AST': 0.5,
 u'FTM_RANK': 6,
 u'DD2': 14,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 0.7,
 u'FG3M': 0.0,
 u'OREB': 0.1,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 4,
 u'FGM': 0.3,
 u'PF': 0.1,
 u'TD3_RANK': 1,
 u'PTS': 0.7,
 u'FGA': 0.6,
 u'FG3M_RANK': 6,
 u'FGA_RANK': 6,
 u'BLKA_RANK': 6,
 u'GP': 28,
 u'STL': 0.1,
 u'AST_RANK': 6,
 u'CFID': 26,
 u'L': 4,
 u'PLUS_MINUS_RANK': 4,
 u'FTA': 0.2,
 u'W': 24,
 u'W_PCT': 0.857,
 u'DREB': 0.3,
 u'FTM': 0.1,
 u'PFD_RANK': 6,
 u'FT_PCT': 0.667,
 u'BLK_RANK': 6,
 u'PFD': 0.1,
 u'MIN_RANK': 6,
 u'OREB_RANK': 6,
 u'FG_PCT': 0.438,
 u'STL_RANK': 6,
 u'GROUP_SET': u'By Score Margin',
 u'FG3_PCT_RANK': 4,
 u'FG3_PCT': 0.333,
 u'FG_PCT_RANK': 6,
 u'TOV_RANK': 6,
 u'BLKA': 0.0,
 u'GP_RANK': 1,
 u'PTS_RANK': 6
 },...
 {
 u'PF_RANK': 5,
 u'FGM_RANK': 4,
 u'FTA_RANK': 3,
 u'BLK': 0.1,
 u'MIN': 5.2,
 u'DREB_RANK': 5,
 u'TOV': 0.8,
 u'TD3': 2,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'more than 20 Points',
 u'REB': 0.9,
 u'DD2_RANK': 6,
 u'REB_RANK': 5,
 u'CFPARAMS': u'more than 20 Points',
 u'W_RANK': 6,
 u'FG3A': 0.8,
 u'AST': 0.8,
 u'FTM_RANK': 3,
 u'DD2': 3,
 u'W_PCT_RANK': 5,
 u'PLUS_MINUS': 1.8,
 u'FG3M': 0.2,
 u'OREB': 0.2,
 u'L_RANK': 6,
 u'FT_PCT_RANK': 1,
 u'FGM': 1.3,
 u'PF': 0.3,
 u'TD3_RANK': 5,
 u'PTS': 3.8,
 u'FGA': 3.0,
 u'FG3M_RANK': 5,
 u'FGA_RANK': 3,
 u'BLKA_RANK': 4,
 u'GP': 12,
 u'STL': 0.4,
 u'AST_RANK': 5,
 u'CFID': 26,
 u'L': 2,
 u'PLUS_MINUS_RANK': 3,
 u'FTA': 1.2,
 u'W': 10,
 u'W_PCT': 0.833,
 u'DREB': 0.8,
 u'FTM': 0.9,
 u'PFD_RANK': 4,
 u'FT_PCT': 0.786,
 u'BLK_RANK': 4,
 u'PFD': 0.9,
 u'MIN_RANK': 5,
 u'OREB_RANK': 4,
 u'FG_PCT': 0.444,
 u'STL_RANK': 2,
 u'GROUP_SET': u'By Score Margin',
 u'FG3_PCT_RANK': 6,
 u'FG3_PCT': 0.222,
 u'FG_PCT_RANK': 5,
 u'TOV_RANK': 3,
 u'BLKA': 0.1,
 u'GP_RANK': 6,
 u'PTS_RANK': 4
}]

player_game_splits.by_actual_margin()

player_game_splits = player.PlayerInGameSplits("2544")
print(player_game_splits.by_actual_margin())

[{
 u'PF_RANK': 2,
 u'FGM_RANK': 10,
 u'FTA_RANK': 11,
 u'BLK': 0.0,
 u'MIN': 1.6,
 u'DREB_RANK': 11,
 u'TOV': 0.0,
 u'TD3': 0,
 u'FG3A_RANK': 11,
 u'GROUP_VALUE': u'Behind more than 20 Points',
 u'REB': 0.0,
 u'DD2_RANK': 10,
 u'REB_RANK': 11,
 u'CFPARAMS': u'Behind more than 20 Points',
 u'W_RANK': 10,
 u'FG3A': 0.0,
 u'AST': 0.5,
 u'FTM_RANK': 11,
 u'DD2': 0,
 u'W_PCT_RANK': 10,
 u'PLUS_MINUS': 3.0,
 u'FG3M': 0.0,
 u'OREB': 0.0,
 u'L_RANK': 8,
 u'FT_PCT_RANK': 11,
 u'FGM': 0.5,
 u'PF': 0.5,
 u'TD3_RANK': 10,
 u'PTS': 1.0,
 u'FGA': 0.5,
 u'FG3M_RANK': 10,
 u'FGA_RANK': 11,
 u'BLKA_RANK': 9,
 u'GP': 2,
 u'STL': 0.0,
 u'AST_RANK': 9,
 u'CFID': 23,
 u'L': 2,
 u'PLUS_MINUS_RANK': 3,
 u'FTA': 0.0,
 u'W': 0,
 u'W_PCT': 0.0,
 u'DREB': 0.0,
 u'FTM': 0.0,
 u'PFD_RANK': 11,
 u'FT_PCT': 0.0,
 u'BLK_RANK': 8,
 u'PFD': 0.0,
 u'MIN_RANK': 11,
 u'OREB_RANK': 10,
 u'FG_PCT': 1.0,
 u'STL_RANK': 11,
 u'GROUP_SET': u'By Actual Margin',
 u'FG3_PCT_RANK': 10,
 u'FG3_PCT': 0.0,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 9,
 u'BLKA': 0.0,
 u'GP_RANK': 11,
 u'PTS_RANK': 10
 },...
 {
 u'PF_RANK': 8,
 u'FGM_RANK': 5,
 u'FTA_RANK': 2,
 u'BLK': 0.1,
 u'MIN': 5.9,
 u'DREB_RANK': 7,
 u'TOV': 0.9,
 u'TD3': 2,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'Ahead more than 20 Points',
 u'REB': 1.1,
 u'DD2_RANK': 9,
 u'REB_RANK': 6,
 u'CFPARAMS': u'Ahead more than 20 Points',
 u'W_RANK': 7,
 u'FG3A': 0.9,
 u'AST': 0.8,
 u'FTM_RANK': 2,
 u'DD2': 3,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 1.5,
 u'FG3M': 0.2,
 u'OREB': 0.2,
 u'L_RANK': 10,
 u'FT_PCT_RANK': 2,
 u'FGM': 1.5,
 u'PF': 0.2,
 u'TD3_RANK': 5,
 u'PTS': 4.3,
 u'FGA': 3.5,
 u'FG3M_RANK': 8,
 u'FGA_RANK': 3,
 u'BLKA_RANK': 5,
 u'GP': 10,
 u'STL': 0.5,
 u'AST_RANK': 7,
 u'CFID': 23,
 u'L': 0,
 u'PLUS_MINUS_RANK': 4,
 u'FTA': 1.4,
 u'W': 10,
 u'W_PCT': 1.0,
 u'DREB': 0.9,
 u'FTM': 1.1,
 u'PFD_RANK': 3,
 u'FT_PCT': 0.786,
 u'BLK_RANK': 4,
 u'PFD': 1.1,
 u'MIN_RANK': 6,
 u'OREB_RANK': 7,
 u'FG_PCT': 0.429,
 u'STL_RANK': 1,
 u'GROUP_SET': u'By Actual Margin',
 u'FG3_PCT_RANK': 9,
 u'FG3_PCT': 0.222,
 u'FG_PCT_RANK': 10,
 u'TOV_RANK': 3,
 u'BLKA': 0.1,
 u'GP_RANK': 8,
 u'PTS_RANK': 5
}]
from nba_py import player – player.PlayerClutchSplits() – endpoint: playerdashboardbyclutch
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_clutch_splits.last5min_deficit_5point()

player_clutch_splits = player.PlayerClutchSplits("2544")
print(player_clutch_splits.last5min_deficit_5point())

[{
 u'PF_RANK': 1,
 u'FGM_RANK': 1,
 u'FTA_RANK': 1,
 u'BLK': 0.0,
 u'MIN': 3.3,
 u'DREB_RANK': 1,
 u'TOV': 0.1,
 u'TD3': 0,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'2016-17',
 u'REB': 1.3,
 u'DD2_RANK': 1,
 u'REB_RANK': 1,
 u'CFPARAMS': u'2016-17',
 u'W_RANK': 1,
 u'FG3A': 0.4,
 u'AST': 1.3,
 u'FTM_RANK': 1,
 u'DD2': 5,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 3.0,
 u'FG3M': 0.3,
 u'OREB': 0.4,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 1,
 u'FGM': 0.9,
 u'PF': 0.4,
 u'TD3_RANK': 1,
 u'PTS': 2.6,
 u'FGA': 1.4,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 7,
 u'STL': 0.1,
 u'AST_RANK': 1,
 u'CFID': 21,
 u'L': 2,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 0.7,
 u'W': 5,
 u'W_PCT': 0.714,
 u'DREB': 0.9,
 u'FTM': 0.6,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.8,
 u'BLK_RANK': 1,
 u'PFD': 0.7,
 u'MIN_RANK': 1,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.6,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Last 5 MIN <= 5 PTS',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.667,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 1,
 u'BLKA': 0.1,
 u'GP_RANK': 1,
 u'PTS_RANK': 1
}]

player_clutch_splits.last3min_deficit_5point()

player_clutch_splits.last1min_deficit_5point()

player_clutch_splits.last30sec_deficit_3point()

player_clutch_splits.last10sec_deficit_3point()

player_clutch_splits.last5min_plusminus_5point()

player_clutch_splits = player.PlayerClutchSplits("2544")
print(player_clutch_splits.last5min_plusminus_5point())

[{ 
 u'PF_RANK': 1,
 u'FGM_RANK': 1,
 u'FTA_RANK': 1,
 u'BLK': 0.1,
 u'MIN': 3.1,
 u'DREB_RANK': 1,
 u'TOV': 0.2,
 u'TD3': 1,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'2016-17',
 u'REB': 1.1,
 u'DD2_RANK': 1,
 u'REB_RANK': 1,
 u'CFPARAMS': u'2016-17',
 u'W_RANK': 1,
 u'FG3A': 0.6,
 u'AST': 1.0,
 u'FTM_RANK': 1,
 u'DD2': 8,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 2.5,
 u'FG3M': 0.4,
 u'OREB': 0.2,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 1,
 u'FGM': 1.0,
 u'PF': 0.4,
 u'TD3_RANK': 1,
 u'PTS': 3.2,
 u'FGA': 1.6,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 14,
 u'STL': 0.1,
 u'AST_RANK': 1,
 u'CFID': 20,
 u'L': 2,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 1.4,
 u'W': 12,
 u'W_PCT': 0.857,
 u'DREB': 0.9,
 u'FTM': 0.9,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.632,
 u'BLK_RANK': 1,
 u'PFD': 0.9,
 u'MIN_RANK': 1,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.636,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Last 5 MIN | +/- 5PTS',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.625,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 1,
 u'BLKA': 0.1,
 u'GP_RANK': 1,
 u'PTS_RANK': 1
}]

player_clutch_splits.last3min_plusminus_5point()

player_clutch_splits.last1min_plusminus_5point()

player_clutch_splits.last30sec_plusminus_5point()

from nba_py import player – player.PlayerShootingSplits() – endpoint: playerdashboardbyshootingsplits
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_shooting_splits.shot_5ft()

player_shooting_splits = player.PlayerShootingSplits("2544")
print(player_shooting_splits.shot_5ft())

[{
 u'PCT_AST_FGM': 0.452,
 u'FGM_RANK': 1,
 u'FGA_RANK': 1,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 3,
 u'PCT_AST_2PM': 0.452,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'Less Than 5 ft.',
 u'FG3A': 0,
 u'EFG_PCT': 0.735,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 1,
 u'PCT_AST_2PM_RANK': 1,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 5,
 u'FGM': 155,
 u'PCT_AST_FGM_RANK': 3,
 u'PCT_UAST_2PM': 0.548,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 9,
 u'CFPARAMS': u'Less Than 5 ft.',
 u'EFG_PCT_RANK': 2,
 u'PCT_UAST_FGM_RANK': 5,
 u'FG_PCT': 0.735,
 u'PCT_UAST_FGM': 0.548,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 211,
 u'FG3_PCT': 0.0,
 u'BLKA': 14,
 u'FG3_PCT_RANK': 4
 },
 {
 u'PCT_AST_FGM': 0.25,
 u'FGM_RANK': 6,
 u'FGA_RANK': 6,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 3,
 u'PCT_AST_2PM': 0.25,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'5-9 ft.',
 u'FG3A': 0,
 u'EFG_PCT': 0.267,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 7,
 u'PCT_AST_2PM_RANK': 2,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 4,
 u'FGM': 12,
 u'PCT_AST_FGM_RANK': 5,
 u'PCT_UAST_2PM': 0.75,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 8,
 u'CFPARAMS': u'5-9 ft.',
 u'EFG_PCT_RANK': 7,
 u'PCT_UAST_FGM_RANK': 3,
 u'FG_PCT': 0.267,
 u'PCT_UAST_FGM': 0.75,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 45,
 u'FG3_PCT': 0.0,
 u'BLKA': 6,
 u'FG3_PCT_RANK': 4
 },
 {
 u'PCT_AST_FGM': 0.222,
 u'FGM_RANK': 5,
 u'FGA_RANK': 4,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 3,
 u'PCT_AST_2PM': 0.222,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'10-14 ft.',
 u'FG3A': 0,
 u'EFG_PCT': 0.367,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 4,
 u'PCT_AST_2PM_RANK': 3,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 3,
 u'FGM': 18,
 u'PCT_AST_FGM_RANK': 6,
 u'PCT_UAST_2PM': 0.778,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 7,
 u'CFPARAMS': u'10-14 ft.',
 u'EFG_PCT_RANK': 6,
 u'PCT_UAST_FGM_RANK': 2,
 u'FG_PCT': 0.367,
 u'PCT_UAST_FGM': 0.778,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 49,
 u'FG3_PCT': 0.0,
 u'BLKA': 2,
 u'FG3_PCT_RANK': 4
 },
 {
 u'PCT_AST_FGM': 0.095,
 u'FGM_RANK': 3,
 u'FGA_RANK': 5,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 3,
 u'PCT_AST_2PM': 0.095,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'15-19 ft.',
 u'FG3A': 0,
 u'EFG_PCT': 0.457,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 3,
 u'PCT_AST_2PM_RANK': 5,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 1,
 u'FGM': 21,
 u'PCT_AST_FGM_RANK': 7,
 u'PCT_UAST_2PM': 0.905,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'15-19 ft.',
 u'EFG_PCT_RANK': 5,
 u'PCT_UAST_FGM_RANK': 1,
 u'FG_PCT': 0.457,
 u'PCT_UAST_FGM': 0.905,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 46,
 u'FG3_PCT': 0.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 4
 },
 {
 u'PCT_AST_FGM': 0.429,
 u'FGM_RANK': 3,
 u'FGA_RANK': 3,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 2,
 u'PCT_AST_2PM': 0.167,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'20-24 ft.',
 u'FG3A': 36,
 u'EFG_PCT': 0.46,
 u'PCT_AST_3PM': 0.533,
 u'FG_PCT_RANK': 6,
 u'PCT_AST_2PM_RANK': 4,
 u'FG3M': 15,
 u'PCT_UAST_2PM_RANK': 2,
 u'FGM': 21,
 u'PCT_AST_FGM_RANK': 4,
 u'PCT_UAST_2PM': 0.833,
 u'FG3M_RANK': 2,
 u'PCT_AST_3PM_RANK': 2,
 u'PCT_UAST_3PM': 0.467,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'20-24 ft.',
 u'EFG_PCT_RANK': 4,
 u'PCT_UAST_FGM_RANK': 4,
 u'FG_PCT': 0.339,
 u'PCT_UAST_FGM': 0.571,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 62,
 u'FG3_PCT': 0.417,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 2
 },
 {
 u'PCT_AST_FGM': 0.529,
 u'FGM_RANK': 2,
 u'FGA_RANK': 2,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 1,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'25-29 ft.',
 u'FG3A': 96,
 u'EFG_PCT': 0.531,
 u'PCT_AST_3PM': 0.529,
 u'FG_PCT_RANK': 5,
 u'PCT_AST_2PM_RANK': 6,
 u'FG3M': 34,
 u'PCT_UAST_2PM_RANK': 6,
 u'FGM': 34,
 u'PCT_AST_FGM_RANK': 2,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 1,
 u'PCT_AST_3PM_RANK': 3,
 u'PCT_UAST_3PM': 0.471,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'25-29 ft.',
 u'EFG_PCT_RANK': 3,
 u'PCT_UAST_FGM_RANK': 6,
 u'FG_PCT': 0.354,
 u'PCT_UAST_FGM': 0.471,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 96,
 u'FG3_PCT': 0.354,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 3
 },
 {
 u'PCT_AST_FGM': 1.0,
 u'FGM_RANK': 7,
 u'FGA_RANK': 7,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 3,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 3,
 u'GROUP_VALUE': u'30-34 ft.',
 u'FG3A': 5,
 u'EFG_PCT': 0.9,
 u'PCT_AST_3PM': 1.0,
 u'FG_PCT_RANK': 2,
 u'PCT_AST_2PM_RANK': 6,
 u'FG3M': 3,
 u'PCT_UAST_2PM_RANK': 6,
 u'FGM': 3,
 u'PCT_AST_FGM_RANK': 1,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 3,
 u'PCT_AST_3PM_RANK': 1,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'30-34 ft.',
 u'EFG_PCT_RANK': 1,
 u'PCT_UAST_FGM_RANK': 7,
 u'FG_PCT': 0.6,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 5,
 u'FG3_PCT': 0.6,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 1
 },
 {
 u'PCT_AST_FGM': 0.0,
 u'FGM_RANK': 8,
 u'FGA_RANK': 8,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 3,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'35-39 ft.',
 u'FG3A': 0,
 u'EFG_PCT': 0.0,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 8,
 u'PCT_AST_2PM_RANK': 6,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 6,
 u'FGM': 0,
 u'PCT_AST_FGM_RANK': 8,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'35-39 ft.',
 u'EFG_PCT_RANK': 8,
 u'PCT_UAST_FGM_RANK': 7,
 u'FG_PCT': 0.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 0,
 u'FG3_PCT': 0.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 4
 },
 {
 u'PCT_AST_FGM': 0.0,
 u'FGM_RANK': 8,
 u'FGA_RANK': 8,
 u'CFID': 47,
 u'PCT_UAST_3PM_RANK': 3,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'40+ ft.',
 u'FG3A': 0,
 u'EFG_PCT': 0.0,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 8,
 u'PCT_AST_2PM_RANK': 6,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 6,
 u'FGM': 0,
 u'PCT_AST_FGM_RANK': 8,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'40+ ft.',
 u'EFG_PCT_RANK': 8,
 u'PCT_UAST_FGM_RANK': 7,
 u'FG_PCT': 0.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGA': 0,
 u'FG3_PCT': 0.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 4
}]

player_shooting_splits.shot_8ft()

player_shooting_splits.shot_areas()

player_shooting_splits = player.PlayerShootingSplits("2544")
print(player_shooting_splits.shot_areas())

[{
 u'PCT_AST_FGM': 0.46,
 u'FGM_RANK': 1,
 u'FGA_RANK': 1,
 u'CFID': 49,
 u'PCT_UAST_3PM_RANK': 4,
 u'PCT_AST_2PM': 0.46,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'Restricted Area',
 u'FG3A': 0,
 u'EFG_PCT': 0.739,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 1,
 u'PCT_AST_2PM_RANK': 1,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 3,
 u'FGM': 150,
 u'PCT_AST_FGM_RANK': 3,
 u'PCT_UAST_2PM': 0.54,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 7,
 u'CFPARAMS': u'Restricted Area',
 u'EFG_PCT_RANK': 2,
 u'PCT_UAST_FGM_RANK': 4,
 u'FG_PCT': 0.739,
 u'PCT_UAST_FGM': 0.54,
 u'GROUP_SET': u'Shot Area',
 u'FGA': 203,
 u'FG3_PCT': 0.0,
 u'BLKA': 14,
 u'FG3_PCT_RANK': 4
 },
 {
 u'PCT_AST_FGM': 0.25,
 u'FGM_RANK': 4,
 u'FGA_RANK': 4,
 u'CFID': 49,
 u'PCT_UAST_3PM_RANK': 4,
 u'PCT_AST_2PM': 0.25,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'In The Paint (Non-RA)',
 u'FG3A': 0,
 u'EFG_PCT': 0.351,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 5,
 u'PCT_AST_2PM_RANK': 2,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 2,
 u'FGM': 20,
 u'PCT_AST_FGM_RANK': 5,
 u'PCT_UAST_2PM': 0.75,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 6,
 u'CFPARAMS': u'In The Paint (Non-RA)',
 u'EFG_PCT_RANK': 6,
 u'PCT_UAST_FGM_RANK': 2,
 u'FG_PCT': 0.351,
 u'PCT_UAST_FGM': 0.75,
 u'GROUP_SET': u'Shot Area',
 u'FGA': 57,
 u'FG3_PCT': 0.0,
 u'BLKA': 6,
 u'FG3_PCT_RANK': 4
 },
 {
 u'PCT_AST_FGM': 0.143,
 u'FGM_RANK': 3,
 u'FGA_RANK': 2,
 u'CFID': 49,
 u'PCT_UAST_3PM_RANK': 4,
 u'PCT_AST_2PM': 0.143,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'Mid-Range',
 u'FG3A': 0,
 u'EFG_PCT': 0.359,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 4,
 u'PCT_AST_2PM_RANK': 3,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 1,
 u'FGM': 42,
 u'PCT_AST_FGM_RANK': 6,
 u'PCT_UAST_2PM': 0.857,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 5,
 u'CFPARAMS': u'Mid-Range',
 u'EFG_PCT_RANK': 5,
 u'PCT_UAST_FGM_RANK': 1,
 u'FG_PCT': 0.359,
 u'PCT_UAST_FGM': 0.857,
 u'GROUP_SET': u'Shot Area',
 u'FGA': 117,
 u'FG3_PCT': 0.0,
 u'BLKA': 2,
 u'FG3_PCT_RANK': 4
 },
 {
 u'PCT_AST_FGM': 0.4,
 u'FGM_RANK': 5,
 u'FGA_RANK': 6,
 u'CFID': 49,
 u'PCT_UAST_3PM_RANK': 1,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 3,
 u'GROUP_VALUE': u'Left Corner 3',
 u'FG3A': 9,
 u'EFG_PCT': 0.833,
 u'PCT_AST_3PM': 0.4,
 u'FG_PCT_RANK': 2,
 u'PCT_AST_2PM_RANK': 4,
 u'FG3M': 5,
 u'PCT_UAST_2PM_RANK': 4,
 u'FGM': 5,
 u'PCT_AST_FGM_RANK': 4,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 2,
 u'PCT_AST_3PM_RANK': 3,
 u'PCT_UAST_3PM': 0.6,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'Left Corner 3',
 u'EFG_PCT_RANK': 1,
 u'PCT_UAST_FGM_RANK': 3,
 u'FG_PCT': 0.556,
 u'PCT_UAST_FGM': 0.6,
 u'GROUP_SET': u'Shot Area',
 u'FGA': 9,
 u'FG3_PCT': 0.556,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 1
 },
 {
 u'PCT_AST_FGM': 0.75,
 u'FGM_RANK': 6,
 u'FGA_RANK': 5,
 u'CFID': 49,
 u'PCT_UAST_3PM_RANK': 3,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'Right Corner 3',
 u'FG3A': 12,
 u'EFG_PCT': 0.5,
 u'PCT_AST_3PM': 0.75,
 u'FG_PCT_RANK': 6,
 u'PCT_AST_2PM_RANK': 4,
 u'FG3M': 4,
 u'PCT_UAST_2PM_RANK': 4,
 u'FGM': 4,
 u'PCT_AST_FGM_RANK': 1,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 3,
 u'PCT_AST_3PM_RANK': 1,
 u'PCT_UAST_3PM': 0.25,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'Right Corner 3',
 u'EFG_PCT_RANK': 4,
 u'PCT_UAST_FGM_RANK': 6,
 u'FG_PCT': 0.333,
 u'PCT_UAST_FGM': 0.25,
 u'GROUP_SET': u'Shot Area',
 u'FGA': 12,
 u'FG3_PCT': 0.333,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 3
 },
 {
 u'PCT_AST_FGM': 0.558,
 u'FGM_RANK': 2,
 u'FGA_RANK': 3,
 u'CFID': 49,
 u'PCT_UAST_3PM_RANK': 2,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'Above the Break 3',
 u'FG3A': 116,
 u'EFG_PCT': 0.556,
 u'PCT_AST_3PM': 0.558,
 u'FG_PCT_RANK': 3,
 u'PCT_AST_2PM_RANK': 4,
 u'FG3M': 43,
 u'PCT_UAST_2PM_RANK': 4,
 u'FGM': 43,
 u'PCT_AST_FGM_RANK': 2,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 1,
 u'PCT_AST_3PM_RANK': 2,
 u'PCT_UAST_3PM': 0.442,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'Above the Break 3',
 u'EFG_PCT_RANK': 3,
 u'PCT_UAST_FGM_RANK': 5,
 u'FG_PCT': 0.371,
 u'PCT_UAST_FGM': 0.442,
 u'GROUP_SET': u'Shot Area',
 u'FGA': 116,
 u'FG3_PCT': 0.371,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 2
 },
 {
 u'PCT_AST_FGM': 0.0,
 u'FGM_RANK': 7,
 u'FGA_RANK': 7,
 u'CFID': 49,
 u'PCT_UAST_3PM_RANK': 4,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'Backcourt',
 u'FG3A': 0,
 u'EFG_PCT': 0.0,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 7,
 u'PCT_AST_2PM_RANK': 4,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 4,
 u'FGM': 0,
 u'PCT_AST_FGM_RANK': 7,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 4,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'Backcourt',
 u'EFG_PCT_RANK': 7,
 u'PCT_UAST_FGM_RANK': 7,
 u'FG_PCT': 0.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Shot Area',
 u'FGA': 0,
 u'FG3_PCT': 0.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 4
}]

player_shooting_splits.assisted_shots()

player_shooting_splits = player.PlayerShootingSplits("2544")
print(player_shooting_splits.assisted_shots())

[{
 u'PCT_AST_FGM': 1.0,
 u'FGM_RANK': 2,
 u'FGA_RANK': 2,
 u'CFID': 46,
 u'PCT_UAST_3PM_RANK': 2,
 u'PCT_AST_2PM': 1.0,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'Assisted',
 u'FG3A': 29,
 u'EFG_PCT': 1.133,
 u'PCT_AST_3PM': 1.0,
 u'FG_PCT_RANK': 1,
 u'PCT_AST_2PM_RANK': 1,
 u'FG3M': 29,
 u'PCT_UAST_2PM_RANK': 2,
 u'FGM': 109,
 u'PCT_AST_FGM_RANK': 1,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 1,
 u'PCT_AST_3PM_RANK': 1,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'Assisted',
 u'EFG_PCT_RANK': 1,
 u'PCT_UAST_FGM_RANK': 2,
 u'FG_PCT': 1.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Assisted Shot',
 u'FGA': 109,
 u'FG3_PCT': 1.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 1},
 {u'PCT_AST_FGM': 0.0,
 u'FGM_RANK': 1,
 u'FGA_RANK': 1,
 u'CFID': 46,
 u'PCT_UAST_3PM_RANK': 1,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'Unassisted',
 u'FG3A': 23,
 u'EFG_PCT': 1.074,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 1,
 u'PCT_AST_2PM_RANK': 2,
 u'FG3M': 23,
 u'PCT_UAST_2PM_RANK': 1,
 u'FGM': 155,
 u'PCT_AST_FGM_RANK': 2,
 u'PCT_UAST_2PM': 1.0,
 u'FG3M_RANK': 2,
 u'PCT_AST_3PM_RANK': 2,
 u'PCT_UAST_3PM': 1.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'Unassisted',
 u'EFG_PCT_RANK': 2,
 u'PCT_UAST_FGM_RANK': 1,
 u'FG_PCT': 1.0,
 u'PCT_UAST_FGM': 1.0,
 u'GROUP_SET': u'Assisted Shot',
 u'FGA': 155,
 u'FG3_PCT': 1.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 1
}]

player_shooting_splits.shot_types_summary()

player_shooting_splits = player.PlayerShootingSplits("2544")
print(player_shooting_splits.shot_types_summary())

[{
 u'PCT_AST_FGM': 1.0,
 u'FG3A': 0,
 u'EFG_PCT': 0.9,
 u'PCT_AST_3PM': 0.0,
 u'CFID': 300,
 u'CFPARAMS': u'Alley Oop',
 u'PCT_UAST_2PM': 0.0,
 u'FG_PCT': 0.9,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 0,
 u'PCT_AST_2PM': 1.0,
 u'FGM': 9,
 u'FG3_PCT': 0.0,
 u'GROUP_VALUE': u'Alley Oop',
 u'PCT_UAST_3PM': 0.0,
 u'BLKA': 0,
 u'FGA': 10
 },
 {
 u'PCT_AST_FGM': 0.444,
 u'FG3A': 1,
 u'EFG_PCT': 0.594,
 u'PCT_AST_3PM': 1.0,
 u'CFID': 300,
 u'CFPARAMS': u'Bank Shot',
 u'PCT_UAST_2PM': 0.625,
 u'FG_PCT': 0.563,
 u'PCT_UAST_FGM': 0.556,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 1,
 u'PCT_AST_2PM': 0.375,
 u'FGM': 9,
 u'FG3_PCT': 1.0,
 u'GROUP_VALUE': u'Bank Shot',
 u'PCT_UAST_3PM': 0.0,
 u'BLKA': 0,
 u'FGA': 16
 },
 {
 u'PCT_AST_FGM': 0.617,
 u'FG3A': 0,
 u'EFG_PCT': 0.959,
 u'PCT_AST_3PM': 0.0,
 u'CFID': 300,
 u'CFPARAMS': u'Dunk',
 u'PCT_UAST_2PM': 0.383,
 u'FG_PCT': 0.959,
 u'PCT_UAST_FGM': 0.383,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 0,
 u'PCT_AST_2PM': 0.617,
 u'FGM': 47,
 u'FG3_PCT': 0.0,
 u'GROUP_VALUE': u'Dunk',
 u'PCT_UAST_3PM': 0.0,
 u'BLKA': 1,
 u'FGA': 49
 },
 {
 u'PCT_AST_FGM': 0.105,
 u'FG3A': 0,
 u'EFG_PCT': 0.442,
 u'PCT_AST_3PM': 0.0,
 u'CFID': 300,
 u'CFPARAMS': u'Fadeaway',
 u'PCT_UAST_2PM': 0.895,
 u'FG_PCT': 0.442,
 u'PCT_UAST_FGM': 0.895,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 0,
 u'PCT_AST_2PM': 0.105,
 u'FGM': 19,
 u'FG3_PCT': 0.0,
 u'GROUP_VALUE': u'Fadeaway',
 u'PCT_UAST_3PM': 0.0,
 u'BLKA': 0,
 u'FGA': 43
 },
 {
 u'PCT_AST_FGM': 0.25,
 u'FG3A': 0,
 u'EFG_PCT': 0.889,
 u'PCT_AST_3PM': 0.0,
 u'CFID': 300,
 u'CFPARAMS': u'Finger Roll',
 u'PCT_UAST_2PM': 0.75,
 u'FG_PCT': 0.889,
 u'PCT_UAST_FGM': 0.75,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 0,
 u'PCT_AST_2PM': 0.25,
 u'FGM': 8,
 u'FG3_PCT': 0.0,
 u'GROUP_VALUE': u'Finger Roll',
 u'PCT_UAST_3PM': 0.0,
 u'BLKA': 0,
 u'FGA': 9
 },
 {
 u'PCT_AST_FGM': 0.0,
 u'FG3A': 0,
 u'EFG_PCT': 0.0,
 u'PCT_AST_3PM': 0.0,
 u'CFID': 300,
 u'CFPARAMS': u'Hook Shot',
 u'PCT_UAST_2PM': 0.0,
 u'FG_PCT': 0.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 0,
 u'PCT_AST_2PM': 0.0,
 u'FGM': 0,
 u'FG3_PCT': 0.0,
 u'GROUP_VALUE': u'Hook Shot',
 u'PCT_UAST_3PM': 0.0,
 u'BLKA': 0,
 u'FGA': 5
 },
 {
 u'PCT_AST_FGM': 0.366,
 u'FG3A': 138,
 u'EFG_PCT': 0.457,
 u'PCT_AST_3PM': 0.558,
 u'CFID': 300,
 u'CFPARAMS': u'Jump Shot',
 u'PCT_UAST_2PM': 0.837,
 u'FG_PCT': 0.363,
 u'PCT_UAST_FGM': 0.634,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 52,
 u'PCT_AST_2PM': 0.163,
 u'FGM': 101,
 u'FG3_PCT': 0.377,
 u'GROUP_VALUE': u'Jump Shot',
 u'PCT_UAST_3PM': 0.442,
 u'BLKA': 10,
 u'FGA': 278
 },
 {
 u'PCT_AST_FGM': 0.408,
 u'FG3A': 0,
 u'EFG_PCT': 0.671,
 u'PCT_AST_3PM': 0.0,
 u'CFID': 300,
 u'CFPARAMS': u'Layup',
 u'PCT_UAST_2PM': 0.592,
 u'FG_PCT': 0.671,
 u'PCT_UAST_FGM': 0.592,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 0,
 u'PCT_AST_2PM': 0.408,
 u'FGM': 98,
 u'FG3_PCT': 0.0,
 u'GROUP_VALUE': u'Layup',
 u'PCT_UAST_3PM': 0.0,
 u'BLKA': 11,
 u'FGA': 146
 },
 {
 u'PCT_AST_FGM': 0.0,
 u'FG3A': 0,
 u'EFG_PCT': 0.0,
 u'PCT_AST_3PM': 0.0,
 u'CFID': 300,
 u'CFPARAMS': u'Tip Shot',
 u'PCT_UAST_2PM': 0.0,
 u'FG_PCT': 0.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Shot Type Summary',
 u'FG3M': 0,
 u'PCT_AST_2PM': 0.0,
 u'FGM': 0,
 u'FG3_PCT': 0.0,
 u'GROUP_VALUE': u'Tip Shot',
 u'PCT_UAST_3PM': 0.0,
 u'BLKA': 0,
 u'FGA': 1
}]

player_shooting_splits.shot_types_detail()

player_shooting_splits = player.PlayerShootingSplits("2544")
print(player_shooting_splits.shot_types_detail())

[{
 u'PCT_AST_FGM': 1.0,
 u'FGM_RANK': 11,
 u'FGA_RANK': 15,
 u'CFID': 50,
 u'PCT_UAST_3PM_RANK': 4,
 u'PCT_AST_2PM': 1.0,
 u'FG3A_RANK': 5,
 u'GROUP_VALUE': u'Alley Oop Dunk Shot',
 u'FG3A': 0,
 u'EFG_PCT': 1.0,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 1,
 u'PCT_AST_2PM_RANK': 1,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 24,
 u'FGM': 6,
 u'PCT_AST_FGM_RANK': 1,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 5,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'Alley Oop Dunk Shot',
 u'EFG_PCT_RANK': 1,
 u'PCT_UAST_FGM_RANK': 24,
 u'FG_PCT': 1.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Shot Type Detail',
 u'FGA': 6,
 u'FG3_PCT': 0.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 5
 },...
 {
 u'PCT_AST_FGM': 0.0,
 u'FGM_RANK': 13,
 u'FGA_RANK': 8,
 u'CFID': 50,
 u'PCT_UAST_3PM_RANK': 4,
 u'PCT_AST_2PM': 0.0,
 u'FG3A_RANK': 5,
 u'GROUP_VALUE': u'Turnaround Jump Shot',
 u'FG3A': 0,
 u'EFG_PCT': 0.333,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT_RANK': 31,
 u'PCT_AST_2PM_RANK': 21,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 1,
 u'FGM': 5,
 u'PCT_AST_FGM_RANK': 23,
 u'PCT_UAST_2PM': 1.0,
 u'FG3M_RANK': 5,
 u'PCT_AST_3PM_RANK': 4,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'Turnaround Jump Shot',
 u'EFG_PCT_RANK': 31,
 u'PCT_UAST_FGM_RANK': 1,
 u'FG_PCT': 0.333,
 u'PCT_UAST_FGM': 1.0,
 u'GROUP_SET': u'Shot Type Detail',
 u'FGA': 15,
 u'FG3_PCT': 0.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 5
}]

player_shooting_splits.assisted_by()

player_shooting_splits = player.PlayerShootingSplits("2544")
print(player_shooting_splits.assisted_by())

[{
 u'PCT_AST_FGM': 1.0,
 u'FGM_RANK': 7,
 u'FGA_RANK': 7,
 u'CFID': 45,
 u'PCT_UAST_3PM_RANK': 1,
 u'PCT_AST_2PM': 1.0,
 u'FG3A_RANK': 9,
 u'PLAYER_ID': 2399,
 u'FG3A': 0,
 u'EFG_PCT': 1.0,
 u'PLAYER_NAME': u'Dunleavy, Mike',
 u'FG_PCT_RANK': 1,
 u'PCT_AST_2PM_RANK': 1,
 u'FG3M': 0,
 u'PCT_UAST_2PM_RANK': 1,
 u'FGM': 3,
 u'PCT_AST_FGM_RANK': 1,
 u'PCT_UAST_FGM_RANK': 1,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 9,
 u'PCT_AST_3PM_RANK': 9,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'2399',
 u'EFG_PCT_RANK': 9,
 u'PCT_AST_3PM': 0.0,
 u'FG_PCT': 1.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Assisted By',
 u'FGA': 3,
 u'FG3_PCT': 0.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 9,
 },...
 {
 u'PCT_AST_FGM': 1.0,
 u'FGM_RANK': 10,
 u'FGA_RANK': 10,
 u'CFID': 45,
 u'PCT_UAST_3PM_RANK': 1,
 u'PCT_AST_2PM': 1.0,
 u'FG3A_RANK': 7,
 u'PLAYER_ID': 202684,
 u'FG3A': 1,
 u'EFG_PCT': 1.25,
 u'PLAYER_NAME': u'Thompson, Tristan',
 u'FG_PCT_RANK': 1,
 u'PCT_AST_2PM_RANK': 1,
 u'FG3M': 1,
 u'PCT_UAST_2PM_RANK': 1,
 u'FGM': 2,
 u'PCT_AST_FGM_RANK': 1,
 u'PCT_UAST_FGM_RANK': 1,
 u'PCT_UAST_2PM': 0.0,
 u'FG3M_RANK': 7,
 u'PCT_AST_3PM_RANK': 1,
 u'PCT_UAST_3PM': 0.0,
 u'BLKA_RANK': 1,
 u'CFPARAMS': u'202684',
 u'EFG_PCT_RANK': 3,
 u'PCT_AST_3PM': 1.0,
 u'FG_PCT': 1.0,
 u'PCT_UAST_FGM': 0.0,
 u'GROUP_SET': u'Assisted By',
 u'FGA': 2,
 u'FG3_PCT': 1.0,
 u'BLKA': 0,
 u'FG3_PCT_RANK': 1
}]
from nba_py import player – player.PlayerPerformanceSplits() – endpoint: playerdashboardbyteamperformance
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_performance_splits.score_differential()

player_performance_splits = player.PlayerPerformanceSplits("2544")
print(player_performance_splits.score_differential())

[{
 u'PF_RANK': 2,
 u'FGM_RANK': 1,
 u'FTA_RANK': 1,
 u'BLK': 0.7,
 u'MIN': 37.2,
 u'DREB_RANK': 1,
 u'TOV': 3.7,
 u'TD3': 3,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'W',
 u'REB': 8.3,
 u'DD2_RANK': 1,
 u'REB_RANK': 1,
 u'CFPARAMS': None,
 u'W_RANK': 1,
 u'FG3A': 5.0,
 u'AST': 9.0,
 u'FTM_RANK': 1,
 u'DD2': 13,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 13.4,
 u'FG3M': 1.9,
 u'OREB': 1.5,
 u'L_RANK': 2,
 u'FT_PCT_RANK': 1,
 u'FGM': 9.6,
 u'PF': 1.5,
 u'TD3_RANK': 1,
 u'PTS': 26.0,
 u'FGA': 18.6,
 u'FG3M_RANK': 1,
 u'CFID': 73,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 24,
 u'STL': 1.4,
 u'AST_RANK': 1,
 u'GROUP_VALUE_ORDER': 0,
 u'L': 0,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 7.1,
 u'W': 24,
 u'W_PCT': 1.0,
 u'DREB': 6.8,
 u'FTM': 4.9,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.688,
 u'BLK_RANK': 1,
 u'PFD': 5.6,
 u'MIN_RANK': 1,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.516,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Score Differential',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.383,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 2,
 u'GROUP_VALUE_2': u'All',
 u'BLKA': 0.8,
 u'GP_RANK': 1,
 u'PTS_RANK': 1
 },...
 {
 u'PF_RANK': 2,
 u'FGM_RANK': 8,
 u'FTA_RANK': 1,
 u'BLK': 0.0,
 u'MIN': 33.3,
 u'DREB_RANK': 8,
 u'TOV': 6.0,
 u'TD3': 0,
 u'FG3A_RANK': 5,
 u'GROUP_VALUE': u'L',
 u'REB': 4.5,
 u'DD2_RANK': 6,
 u'REB_RANK': 8,
 u'CFPARAMS': None,
 u'W_RANK': 6,
 u'FG3A': 5.0,
 u'AST': 4.5,
 u'FTM_RANK': 6,
 u'DD2': 0,
 u'W_PCT_RANK': 6,
 u'PLUS_MINUS': -16.0,
 u'FG3M': 1.5,
 u'OREB': 0.5,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 7,
 u'FGM': 6.5,
 u'PF': 2.5,
 u'TD3_RANK': 4,
 u'PTS': 19.0,
 u'FGA': 15.0,
 u'FG3M_RANK': 5,
 u'CFID': 83,
 u'FGA_RANK': 7,
 u'BLKA_RANK': 6,
 u'GP': 2,
 u'STL': 1.0,
 u'AST_RANK': 8,
 u'GROUP_VALUE_ORDER': 4,
 u'L': 2,
 u'PLUS_MINUS_RANK': 8,
 u'FTA': 9.0,
 u'W': 0,
 u'W_PCT': 0.0,
 u'DREB': 4.0,
 u'FTM': 4.5,
 u'PFD_RANK': 3,
 u'FT_PCT': 0.5,
 u'BLK_RANK': 5,
 u'PFD': 5.5,
 u'MIN_RANK': 6,
 u'OREB_RANK': 7,
 u'FG_PCT': 0.433,
 u'STL_RANK': 6,
 u'GROUP_SET': u'Score Differential',
 u'FG3_PCT_RANK': 7,
 u'FG3_PCT': 0.3,
 u'FG_PCT_RANK': 8,
 u'TOV_RANK': 2,
 u'GROUP_VALUE_2': u'16-20 Points ',
 u'BLKA': 0.5,
 u'GP_RANK': 5,
 u'PTS_RANK': 8
}]

player_performance_splits.points_scored()

player_performance_splits = player.PlayerPerformanceSplits("2544")
print(player_performance_splits.points_scored())

[{
 u'PF_RANK': 2,
 u'FGM_RANK': 1,
 u'FTA_RANK': 1,
 u'BLK': 0.7,
 u'MIN': 37.2,
 u'DREB_RANK': 1,
 u'TOV': 3.7,
 u'TD3': 3,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'W',
 u'REB': 8.3,
 u'DD2_RANK': 1,
 u'REB_RANK': 1,
 u'CFPARAMS': None,
 u'W_RANK': 1,
 u'FG3A': 5.0,
 u'AST': 9.0,
 u'FTM_RANK': 1,
 u'DD2': 13,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 13.4,
 u'FG3M': 1.9,
 u'OREB': 1.5,
 u'L_RANK': 2,
 u'FT_PCT_RANK': 1,
 u'FGM': 9.6,
 u'PF': 1.5,
 u'TD3_RANK': 1,
 u'PTS': 26.0,
 u'FGA': 18.6,
 u'FG3M_RANK': 1,
 u'CFID': 51,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 24,
 u'STL': 1.4,
 u'AST_RANK': 1,
 u'GROUP_VALUE_ORDER': 0,
 u'L': 0,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 7.1,
 u'W': 24,
 u'W_PCT': 1.0,
 u'DREB': 6.8,
 u'FTM': 4.9,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.688,
 u'BLK_RANK': 1,
 u'PFD': 5.6,
 u'MIN_RANK': 1,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.516,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Points Scored',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.383,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 2,
 u'GROUP_VALUE_2': u'All',
 u'BLKA': 0.8,
 u'GP_RANK': 1,
 u'PTS_RANK': 1
 },...
 {
 u'PF_RANK': 1,
 u'FGM_RANK': 2,
 u'FTA_RANK': 4,
 u'BLK': 0.0,
 u'MIN': 38.1,
 u'DREB_RANK': 3,
 u'TOV': 5.3,
 u'TD3': 0,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'L',
 u'REB': 6.0,
 u'DD2_RANK': 2,
 u'REB_RANK': 3,
 u'CFPARAMS': None,
 u'W_RANK': 3,
 u'FG3A': 5.3,
 u'AST': 7.3,
 u'FTM_RANK': 4,
 u'DD2': 1,
 u'W_PCT_RANK': 3,
 u'PLUS_MINUS': -2.7,
 u'FG3M': 2.0,
 u'OREB': 0.7,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 3,
 u'FGM': 9.7,
 u'PF': 2.7,
 u'TD3_RANK': 2,
 u'PTS': 24.0,
 u'FGA': 18.3,
 u'FG3M_RANK': 1,
 u'CFID': 60,
 u'FGA_RANK': 2,
 u'BLKA_RANK': 3,
 u'GP': 3,
 u'STL': 1.0,
 u'AST_RANK': 2,
 u'GROUP_VALUE_ORDER': 6,
 u'L': 3,
 u'PLUS_MINUS_RANK': 3,
 u'FTA': 4.0,
 u'W': 0,
 u'W_PCT': 0.0,
 u'DREB': 5.3,
 u'FTM': 2.7,
 u'PFD_RANK': 4,
 u'FT_PCT': 0.667,
 u'BLK_RANK': 4,
 u'PFD': 3.7,
 u'MIN_RANK': 2,
 u'OREB_RANK': 4,
 u'FG_PCT': 0.527,
 u'STL_RANK': 3,
 u'GROUP_SET': u'Points Scored',
 u'FG3_PCT_RANK': 2,
 u'FG3_PCT': 0.375,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 1,
 u'GROUP_VALUE_2': u'100+ Points ',
 u'BLKA': 0.7,
 u'GP_RANK': 2,
 u'PTS_RANK': 2
}]

player_performance_splits.points_against()

player_performance_splits = player.PlayerPerformanceSplits("2544")
print(player_performance_splits.points_against())

[{
 u'PF_RANK': 2,
 u'FGM_RANK': 1,
 u'FTA_RANK': 1,
 u'BLK': 0.7,
 u'MIN': 37.2,
 u'DREB_RANK': 1,
 u'TOV': 3.7,
 u'TD3': 3,
 u'FG3A_RANK': 1,
 u'GROUP_VALUE': u'W',
 u'REB': 8.3,
 u'DD2_RANK': 1,
 u'REB_RANK': 1,
 u'CFPARAMS': None,
 u'W_RANK': 1,
 u'FG3A': 5.0,
 u'AST': 9.0,
 u'FTM_RANK': 1,
 u'DD2': 13,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 13.4,
 u'FG3M': 1.9,
 u'OREB': 1.5,
 u'L_RANK': 2,
 u'FT_PCT_RANK': 1,
 u'FGM': 9.6,
 u'PF': 1.5,
 u'TD3_RANK': 1,
 u'PTS': 26.0,
 u'FGA': 18.6,
 u'FG3M_RANK': 1,
 u'CFID': 61,
 u'FGA_RANK': 1,
 u'BLKA_RANK': 1,
 u'GP': 24,
 u'STL': 1.4,
 u'AST_RANK': 1,
 u'GROUP_VALUE_ORDER': 0,
 u'L': 0,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 7.1,
 u'W': 24,
 u'W_PCT': 1.0,
 u'DREB': 6.8,
 u'FTM': 4.9,
 u'PFD_RANK': 1,
 u'FT_PCT': 0.688,
 u'BLK_RANK': 1,
 u'PFD': 5.6,
 u'MIN_RANK': 1,
 u'OREB_RANK': 1,
 u'FG_PCT': 0.516,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Points Against',
 u'FG3_PCT_RANK': 1,
 u'FG3_PCT': 0.383,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 2,
 u'GROUP_VALUE_2': u'All',
 u'BLKA': 0.8,
 u'GP_RANK': 1,
 u'PTS_RANK': 1},
 {u'PF_RANK': 2,
 u'FGM_RANK': 2,
 u'FTA_RANK': 4,
 u'BLK': 0.5,
 u'MIN': 33.6,
 u'DREB_RANK': 3,
 u'TOV': 3.8,
 u'TD3': 1,
 u'FG3A_RANK': 4,
 u'GROUP_VALUE': u'W',
 u'REB': 7.0,
 u'DD2_RANK': 3,
 u'REB_RANK': 2,
 u'CFPARAMS': None,
 u'W_RANK': 3,
 u'FG3A': 3.3,
 u'AST': 8.3,
 u'FTM_RANK': 4,
 u'DD2': 1,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 19.3,
 u'FG3M': 0.5,
 u'OREB': 1.5,
 u'L_RANK': 2,
 u'FT_PCT_RANK': 4,
 u'FGM': 9.8,
 u'PF': 1.8,
 u'TD3_RANK': 2,
 u'PTS': 22.5,
 u'FGA': 16.8,
 u'FG3M_RANK': 4,
 u'CFID': 65,
 u'FGA_RANK': 3,
 u'BLKA_RANK': 4,
 u'GP': 4,
 u'STL': 1.5,
 u'AST_RANK': 2,
 u'GROUP_VALUE_ORDER': 4,
 u'L': 0,
 u'PLUS_MINUS_RANK': 1,
 u'FTA': 4.3,
 u'W': 4,
 u'W_PCT': 1.0,
 u'DREB': 5.5,
 u'FTM': 2.5,
 u'PFD_RANK': 3,
 u'FT_PCT': 0.588,
 u'BLK_RANK': 3,
 u'PFD': 4.8,
 u'MIN_RANK': 4,
 u'OREB_RANK': 2,
 u'FG_PCT': 0.582,
 u'STL_RANK': 1,
 u'GROUP_SET': u'Points Against',
 u'FG3_PCT_RANK': 4,
 u'FG3_PCT': 0.154,
 u'FG_PCT_RANK': 1,
 u'TOV_RANK': 3,
 u'GROUP_VALUE_2': u'80-89 Points',
 u'BLKA': 0.3,
 u'GP_RANK': 3,
 u'PTS_RANK': 2
 },...
 {
 u'PF_RANK': 1,
 u'FGM_RANK': 3,
 u'FTA_RANK': 3,
 u'BLK': 0.0,
 u'MIN': 37.0,
 u'DREB_RANK': 4,
 u'TOV': 5.3,
 u'TD3': 0,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'L',
 u'REB': 5.8,
 u'DD2_RANK': 3,
 u'REB_RANK': 4,
 u'CFPARAMS': None,
 u'W_RANK': 4,
 u'FG3A': 4.5,
 u'AST': 6.8,
 u'FTM_RANK': 3,
 u'DD2': 1,
 u'W_PCT_RANK': 4,
 u'PLUS_MINUS': -7.0,
 u'FG3M': 1.5,
 u'OREB': 0.8,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 3,
 u'FGM': 8.5,
 u'PF': 2.5,
 u'TD3_RANK': 3,
 u'PTS': 22.0,
 u'FGA': 17.3,
 u'FG3M_RANK': 3,
 u'CFID': 72,
 u'FGA_RANK': 2,
 u'BLKA_RANK': 2,
 u'GP': 4,
 u'STL': 1.3,
 u'AST_RANK': 4,
 u'GROUP_VALUE_ORDER': 6,
 u'L': 4,
 u'PLUS_MINUS_RANK': 4,
 u'FTA': 5.8,
 u'W': 0,
 u'W_PCT': 0.0,
 u'DREB': 5.0,
 u'FTM': 3.5,
 u'PFD_RANK': 4,
 u'FT_PCT': 0.609,
 u'BLK_RANK': 4,
 u'PFD': 4.3,
 u'MIN_RANK': 2,
 u'OREB_RANK': 4,
 u'FG_PCT': 0.493,
 u'STL_RANK': 4,
 u'GROUP_SET': u'Points Against',
 u'FG3_PCT_RANK': 3,
 u'FG3_PCT': 0.333,
 u'FG_PCT_RANK': 3,
 u'TOV_RANK': 1,
 u'GROUP_VALUE_2': u'100+ Points ',
 u'BLKA': 0.8,
 u'GP_RANK': 3,
 u'PTS_RANK': 3
}]
from nba_py import player – player.PlayerYearOverYearSplits() – endpoint: playerdashboardbyyearoveryear
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_yearoveryear_splits.by_year()

player_yearoveryear_splits = player.PlayerYearOverYearSplits("2544")
print(player_yearoveryear_splits.by_year())

[{
 u'PF_RANK': 10,
 u'FGM_RANK': 12,
 u'FTA_RANK': 12,
 u'BLK': 0.6,
 u'MIN': 37.1,
 u'DREB_RANK': 2,
 u'TOV': 3.9,
 u'TD3': 3,
 u'FG3A_RANK': 2,
 u'GROUP_VALUE': u'2016-17',
 u'REB': 7.9,
 u'DD2_RANK': 12,
 u'REB_RANK': 3,
 u'CFPARAMS': u'2016-17',
 u'W_RANK': 14,
 u'FG3A': 4.9,
 u'AST': 8.6,
 u'FTM_RANK': 13,
 u'DD2': 14,
 u'W_PCT_RANK': 1,
 u'PLUS_MINUS': 10.5,
 u'FG3M': 1.9,
 u'OREB': 1.4,
 u'L_RANK': 14,
 u'FT_PCT_RANK': 14,
 u'FGM': 9.4,
 u'PF': 1.6,
 u'TD3_RANK': 8,
 u'PTS': 25.4,
 u'FGA': 18.4,
 u'FG3M_RANK': 1,
 u'FGA_RANK': 12,
 u'BLKA_RANK': 6,
 u'GP': 28,
 u'STL': 1.4,
 u'AST_RANK': 1,
 u'CFID': 264,
 u'L': 4,
 u'PLUS_MINUS_RANK': 2,
 u'FTA': 6.9,
 u'W': 24,
 u'W_PCT': 0.857,
 u'DREB': 6.5,
 u'FTM': 4.7,
 u'PFD_RANK': 12,
 u'FT_PCT': 0.679,
 u'BLK_RANK': 13,
 u'PFD': 5.4,
 u'MIN_RANK': 12,
 u'OREB_RANK': 4,
 u'FG_PCT': 0.513,
 u'STL_RANK': 13,
 u'GROUP_SET': u'By Year',
 u'FG3_PCT_RANK': 3,
 u'FG3_PCT': 0.377,
 u'FG_PCT_RANK': 5,
 u'TOV_RANK': 2,
 u'BLKA': 0.8,
 u'GP_RANK': 14,
 u'PTS_RANK': 11
 },...
 {
 u'PF_RANK': 6,
 u'FGM_RANK': 14,
 u'FTA_RANK': 14,
 u'BLK': 0.7,
 u'MIN': 39.6,
 u'DREB_RANK': 14,
 u'TOV': 3.5,
 u'TD3': 0,
 u'FG3A_RANK': 13,
 u'GROUP_VALUE': u'2003-04',
 u'REB': 5.5,
 u'DD2_RANK': 13,
 u'REB_RANK': 14,
 u'CFPARAMS': u'2003-04',
 u'W_RANK': 13,
 u'FG3A': 2.7,
 u'AST': 5.9,
 u'FTM_RANK': 14,
 u'DD2': 12,
 u'W_PCT_RANK': 14,
 u'PLUS_MINUS': -1.8,
 u'FG3M': 0.8,
 u'OREB': 1.3,
 u'L_RANK': 1,
 u'FT_PCT_RANK': 5,
 u'FGM': 7.9,
 u'PF': 1.9,
 u'TD3_RANK': 13,
 u'PTS': 20.9,
 u'FGA': 18.9,
 u'FG3M_RANK': 14,
 u'FGA_RANK': 7,
 u'BLKA_RANK': 1,
 u'GP': 79,
 u'STL': 1.6,
 u'AST_RANK': 14,
 u'CFID': 264,
 u'L': 46,
 u'PLUS_MINUS_RANK': 14,
 u'FTA': 5.8,
 u'W': 33,
 u'W_PCT': 0.418,
 u'DREB': 4.2,
 u'FTM': 4.4,
 u'PFD_RANK': 14,
 u'FT_PCT': 0.754,
 u'BLK_RANK': 7,
 u'PFD': 0.0,
 u'MIN_RANK': 5,
 u'OREB_RANK': 8,
 u'FG_PCT': 0.417,
 u'STL_RANK': 6,
 u'GROUP_SET': u'By Year',
 u'FG3_PCT_RANK': 14,
 u'FG3_PCT': 0.29,
 u'FG_PCT_RANK': 14,
 u'TOV_RANK': 5,
 u'BLKA': 1.0,
 u'GP_RANK': 3,
 u'PTS_RANK': 14
}]
from nba_py import player – player.PlayerCareer() – endpoint: playercareerstats
player_id: "2544" (required),
per_mode: "PerGame" (constants.PerMode.Default),
league_id: "00" (constants.League.Default)

player_career.regular_season_totals()

player_career = player.PlayerCareer("2544")
print(player_career.regular_season_totals())

[{
 u'MIN': 39.5,
 u'TOV': 3.5,
 u'REB': 5.5,
 u'TEAM_ID': 1610612739,
 u'PLAYER_ID': 2544,
 u'FG3A': 2.7,
 u'PLAYER_AGE': 19.0,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG3M': 0.8,
 u'OREB': 1.3,
 u'FGM': 7.9,
 u'PF': 1.9,
 u'PTS': 20.9,
 u'FGA': 18.9,
 u'GS': 79,
 u'GP': 79,
 u'STL': 1.6,
 u'FTA': 5.8,
 u'BLK': 0.7,
 u'DREB': 4.2,
 u'FTM': 4.4,
 u'FT_PCT': 0.754,
 u'SEASON_ID': u'2003-04',
 u'FG_PCT': 0.417,
 u'AST': 5.9,
 u'FG3_PCT': 0.29
 },...
 {
 u'MIN': 37.1,
 u'TOV': 3.9,
 u'REB': 7.9,
 u'TEAM_ID': 1610612739,
 u'PLAYER_ID': 2544,
 u'FG3A': 4.9,
 u'PLAYER_AGE': 32.0,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG3M': 1.9,
 u'OREB': 1.4,
 u'FGM': 9.4,
 u'PF': 1.6,
 u'PTS': 25.4,
 u'FGA': 18.4,
 u'GS': 28,
 u'GP': 28,
 u'STL': 1.4,
 u'FTA': 6.9,
 u'BLK': 0.6,
 u'DREB': 6.5,
 u'FTM': 4.7,
 u'FT_PCT': 0.679,
 u'SEASON_ID': u'2016-17',
 u'FG_PCT': 0.513,
 u'AST': 8.6,
 u'FG3_PCT': 0.377
}]

player_career.regular_season_career_totals()

player_career = player.PlayerCareer("2544")
print(player_career.regular_season_career_totals())

[{
 u'MIN': 38.9,
 u'TOV': 3.4,
 u'REB': 7.2,
 u'PLAYER_ID': 2544,
 u'FG3A': 4.0,
 u'AST': 7.0,
 u'LEAGUE_ID': u'00',
 u'FG3M': 1.4,
 u'OREB': 1.2,
 u'FGM': 9.8,
 u'PF': 1.9,
 u'PTS': 27.1,
 u'FGA': 19.7,
 u'GS': 1014,
 u'GP': 1015,
 u'STL': 1.7,
 u'FTA': 8.3,
 u'BLK': 0.8,
 u'DREB': 6.0,
 u'FTM': 6.2,
 u'FT_PCT': 0.742,
 u'FG_PCT': 0.498,
 u'Team_ID': 0,
 u'FG3_PCT': 0.341
}]

player_career.post_season_totals()

player_career = player.PlayerCareer("2544")
print(player_career.post_season_totals())

[{
 u'MIN': 46.5,
 u'TOV': 5.0,
 u'REB': 8.1,
 u'TEAM_ID': 1610612739,
 u'PLAYER_ID': 2544,
 u'FG3A': 4.8,
 u'PLAYER_AGE': 21.0,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG3M': 1.6,
 u'OREB': 1.7,
 u'FGM': 11.2,
 u'PF': 3.4,
 u'PTS': 30.8,
 u'FGA': 23.6,
 u'GS': 13,
 u'GP': 13,
 u'STL': 1.4,
 u'FTA': 9.1,
 u'BLK': 0.7,
 u'DREB': 6.4,
 u'FTM': 6.7,
 u'FT_PCT': 0.737,
 u'SEASON_ID': u'2005-06',
 u'FG_PCT': 0.476,
 u'AST': 5.8,
 u'FG3_PCT': 0.333
 },...
 {
 u'MIN': 39.1,
 u'TOV': 3.6,
 u'REB': 9.5,
 u'TEAM_ID': 1610612739,
 u'PLAYER_ID': 2544,
 u'FG3A': 4.5,
 u'PLAYER_AGE': 31.0,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG3M': 1.5,
 u'OREB': 2.0,
 u'FGM': 10.4,
 u'PF': 2.6,
 u'PTS': 26.3,
 u'FGA': 19.9,
 u'GS': 21,
 u'GP': 21,
 u'STL': 2.3,
 u'FTA': 5.9,
 u'BLK': 1.3,
 u'DREB': 7.5,
 u'FTM': 3.9,
 u'FT_PCT': 0.661,
 u'SEASON_ID': u'2015-16',
 u'FG_PCT': 0.525,
 u'AST': 7.6,
 u'FG3_PCT': 0.34
}]

player_career.post_season_career_totals()

player_career = player.PlayerCareer("2544")
print(player_career.post_season_career_totals())

[{
 u'MIN': 42.1,
 u'TOV': 3.5,
 u'REB': 8.8,
 u'PLAYER_ID': 2544,
 u'FG3A': 4.5,
 u'AST': 6.8,
 u'LEAGUE_ID': u'00',
 u'FG3M': 1.4,
 u'OREB': 1.6,
 u'FGM': 9.9,
 u'PF': 2.4,
 u'PTS': 28.0,
 u'FGA': 20.7,
 u'GS': 199,
 u'GP': 199,
 u'STL': 1.8,
 u'FTA': 9.1,
 u'BLK': 0.9,
 u'DREB': 7.2,
 u'FTM': 6.8,
 u'FT_PCT': 0.746,
 u'FG_PCT': 0.478,
 u'Team_ID': 0,
 u'FG3_PCT': 0.321
}]

player_career.all_star_season_totals()

player_career = player.PlayerCareer("2544")
print(player_career.all_star_season_totals())

[{
 u'MIN': 31.0,
 u'TOV': 3.0,
 u'REB': 8.0,
 u'TEAM_ID': 1610616833,
 u'PLAYER_ID': 2544,
 u'FG3A': 4.0,
 u'PLAYER_AGE': 20.0,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'EST',
 u'FG3M': 1.0,
 u'OREB': 1.0,
 u'FGM': 6.0,
 u'PF': 0.0,
 u'PTS': 13.0,
 u'FGA': 13.0,
 u'GS': 1,
 u'GP': 1,
 u'STL': 2.0,
 u'FTA': 1.0,
 u'BLK': 0.0,
 u'DREB': 7.0,
 u'FTM': 0.0,
 u'FT_PCT': 0.0,
 u'SEASON_ID': u'2004-05',
 u'FG_PCT': 0.462,
 u'AST': 6.0,
 u'FG3_PCT': 0.25
 },...
 {
 u'MIN': 20.2,
 u'TOV': 4.0,
 u'REB': 4.0,
 u'TEAM_ID': 1610616833,
 u'PLAYER_ID': 2544,
 u'FG3A': 5.0,
 u'PLAYER_AGE': 31.0,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'EST',
 u'FG3M': 1.0,
 u'OREB': 0.0,
 u'FGM': 6.0,
 u'PF': 0.0,
 u'PTS': 13.0,
 u'FGA': 13.0,
 u'GS': 1,
 u'GP': 1,
 u'STL': 0.0,
 u'FTA': 0.0,
 u'BLK': 0.0,
 u'DREB': 4.0,
 u'FTM': 0.0,
 u'FT_PCT': 0.0,
 u'SEASON_ID': u'2015-16',
 u'FG_PCT': 0.462,
 u'AST': 7.0,
 u'FG3_PCT': 0.2
}]

player_career.college_season_totals()

player_career = player.PlayerCareer("2544")
print(player_career.college_season_totals())

[]

player_career.college_season_career_totals()

player_career = player.PlayerCareer("2544")
print(player_career.college_season_career_totals())

[]

player_career.regular_season_rankings()

player_career = player.PlayerCareer("2544")
print(player_career.regular_season_rankings())

[{
 u'RANK_PG_FTA': 13,
 u'RANK_PG_FTM': 20,
 u'PLAYER_ID': 2544,
 u'TEAM_ID': 1610612739,
 u'RANK_PG_FG3M': 69,
 u'RANK_PG_FG3A': 55,
 u'RANK_PG_REB': 58,
 u'RANK_PG_PTS': 13,
 u'RANK_PG_EFF': 31,
 u'RANK_PG_STL': 13,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PLAYER_AGE': u'NR',
 u'RANK_PG_OREB': 83,
 u'RANK_PG_DREB': 51,
 u'GS': u'NR',
 u'GP': u'NR',
 u'RANK_PG_MIN': 10,
 u'RANK_FG3_PCT': 92,
 u'SEASON_ID': u'2003-04',
 u'RANK_PG_AST': 13,
 u'RANK_PG_BLK': 51,
 u'RANK_PG_TOV': 5,
 u'RANK_PG_FGM': 10,
 u'RANK_FT_PCT': 73,
 u'RANK_FG_PCT': 90,
 u'RANK_PG_FGA': 5
 },...
 {
 u'RANK_PG_FTA': 20,
 u'RANK_PG_FTM': 20,
 u'PLAYER_ID': 2544,
 u'TEAM_ID': 1610612739,
 u'RANK_PG_FG3M': 41,
 u'RANK_PG_FG3A': 41,
 u'RANK_PG_REB': 28,
 u'RANK_PG_PTS': 9,
 u'RANK_PG_EFF': 6,
 u'RANK_PG_STL': 25,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PLAYER_AGE': u'NR',
 u'RANK_PG_OREB': 77,
 u'RANK_PG_DREB': 20,
 u'GS': u'NR',
 u'GP': u'NR',
 u'RANK_PG_MIN': 3,
 u'RANK_FG3_PCT': 57,
 u'SEASON_ID': u'2016-17',
 u'RANK_PG_AST': 5,
 u'RANK_PG_BLK': 65,
 u'RANK_PG_TOV': 4,
 u'RANK_PG_FGM': 5,
 u'RANK_FT_PCT': 97,
 u'RANK_FG_PCT': 24,
 u'RANK_PG_FGA': 5
}]

player_career.post_season_rankings()

player_career = player.PlayerCareer("2544")
print(player_career.post_season_rankings())

[{
 u'RANK_PG_FTA': 8,
 u'RANK_PG_FTM': 8,
 u'PLAYER_ID': 2544,
 u'TEAM_ID': 1610612739,
 u'RANK_PG_FG3M': 11,
 u'RANK_PG_FG3A': 10,
 u'RANK_PG_REB': 12,
 u'RANK_PG_PTS': 2,
 u'RANK_PG_EFF': 7,
 u'RANK_PG_STL': 12,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PLAYER_AGE': u'NR',
 u'RANK_PG_OREB': 34,
 u'RANK_PG_DREB': 12,
 u'GS': u'NR',
 u'GP': u'NR',
 u'RANK_PG_MIN': 2,
 u'RANK_FG3_PCT': 43,
 u'SEASON_ID': u'2005-06',
 u'RANK_PG_AST': 7,
 u'RANK_PG_BLK': 30,
 u'RANK_PG_TOV': 1,
 u'RANK_PG_FGM': 1,
 u'RANK_FT_PCT': 53,
 u'RANK_FG_PCT': 26,
 u'RANK_PG_FGA': 1
 },...
 {
 u'RANK_PG_FTA': 16,
 u'RANK_PG_FTM': 16,
 u'PLAYER_ID': 2544,
 u'TEAM_ID': 1610612739,
 u'RANK_PG_FG3M': 33,
 u'RANK_PG_FG3A': 33,
 u'RANK_PG_REB': 6,
 u'RANK_PG_PTS': 5,
 u'RANK_PG_EFF': 1,
 u'RANK_PG_STL': 5,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PLAYER_AGE': u'NR',
 u'RANK_PG_OREB': 20,
 u'RANK_PG_DREB': 7,
 u'GS': u'NR',
 u'GP': u'NR',
 u'RANK_PG_MIN': 6,
 u'RANK_FG3_PCT': 35,
 u'SEASON_ID': u'2015-16',
 u'RANK_PG_AST': 3,
 u'RANK_PG_BLK': 16,
 u'RANK_PG_TOV': 5,
 u'RANK_PG_FGM': 1,
 u'RANK_FT_PCT': 46,
 u'RANK_FG_PCT': 6,
 u'RANK_PG_FGA': 1
}]
from nba_py import player – player.PlayerProfile() – endpoint: playerprofilev2
player_id: "2544" (required),
per_mode: "PerGame" (constants.PerMode.Default),
league_id: "00" (constants.League.Default)

player_profile.season_highs()

player_profile = player.PlayerProfile("2544")
print(player_profile.season_highs())

[{
 u'RANK_PG_FTA': 13,
 u'RANK_PG_FTM': 20,
 u'PLAYER_ID': 2544,
 u'TEAM_ID': 1610612739,
 u'RANK_PG_FG3M': 69,
 u'RANK_PG_FG3A': 55,
 u'RANK_PG_REB': 58,
 u'RANK_PG_PTS': 13,
 u'RANK_PG_EFF': 31,
 u'RANK_PG_STL': 13,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PLAYER_AGE': u'NR',
 u'RANK_PG_OREB': 83,
 u'RANK_PG_DREB': 51,
 u'GS': u'NR',
 u'GP': u'NR',
 u'RANK_PG_MIN': 10,
 u'RANK_FG3_PCT': 92,
 u'SEASON_ID': u'2003-04',
 u'RANK_PG_AST': 13,
 u'RANK_PG_BLK': 51,
 u'RANK_PG_TOV': 5,
 u'RANK_PG_FGM': 10,
 u'RANK_FT_PCT': 73,
 u'RANK_FG_PCT': 90,
 u'RANK_PG_FGA': 5
 },...
 {
 u'RANK_PG_FTA': 21,
 u'RANK_PG_FTM': 21,
 u'PLAYER_ID': 2544,
 u'TEAM_ID': 1610612739,
 u'RANK_PG_FG3M': 40,
 u'RANK_PG_FG3A': 40,
 u'RANK_PG_REB': 28,
 u'RANK_PG_PTS': 9,
 u'RANK_PG_EFF': 6,
 u'RANK_PG_STL': 26,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PLAYER_AGE': u'NR',
 u'RANK_PG_OREB': 77,
 u'RANK_PG_DREB': 21,
 u'GS': u'NR',
 u'GP': u'NR',
 u'RANK_PG_MIN': 3,
 u'RANK_FG3_PCT': 56,
 u'SEASON_ID': u'2016-17',
 u'RANK_PG_AST': 5,
 u'RANK_PG_BLK': 64,
 u'RANK_PG_TOV': 4,
 u'RANK_PG_FGM': 5,
 u'RANK_FT_PCT': 97,
 u'RANK_FG_PCT': 24,
 u'RANK_PG_FGA': 5
}]

player_profile.career_highs()

player_profile = player.PlayerProfile("2544")
print(player_profile.career_highs())

[{
 u'RANK_PG_FTA': 8,
 u'RANK_PG_FTM': 8,
 u'PLAYER_ID': 2544,
 u'TEAM_ID': 1610612739,
 u'RANK_PG_FG3M': 11,
 u'RANK_PG_FG3A': 10,
 u'RANK_PG_REB': 12,
 u'RANK_PG_PTS': 2,
 u'RANK_PG_EFF': 7,
 u'RANK_PG_STL': 12,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PLAYER_AGE': u'NR',
 u'RANK_PG_OREB': 34,
 u'RANK_PG_DREB': 12,
 u'GS': u'NR',
 u'GP': u'NR',
 u'RANK_PG_MIN': 2,
 u'RANK_FG3_PCT': 43,
 u'SEASON_ID': u'2005-06',
 u'RANK_PG_AST': 7,
 u'RANK_PG_BLK': 30,
 u'RANK_PG_TOV': 1,
 u'RANK_PG_FGM': 1,
 u'RANK_FT_PCT': 53,
 u'RANK_FG_PCT': 26,
 u'RANK_PG_FGA': 1
 },...
 {
 u'RANK_PG_FTA': 16,
 u'RANK_PG_FTM': 16,
 u'PLAYER_ID': 2544,
 u'TEAM_ID': 1610612739,
 u'RANK_PG_FG3M': 33,
 u'RANK_PG_FG3A': 33,
 u'RANK_PG_REB': 6,
 u'RANK_PG_PTS': 5,
 u'RANK_PG_EFF': 1,
 u'RANK_PG_STL': 5,
 u'LEAGUE_ID': u'00',
 u'TEAM_ABBREVIATION': u'CLE',
 u'PLAYER_AGE': u'NR',
 u'RANK_PG_OREB': 20,
 u'RANK_PG_DREB': 7,
 u'GS': u'NR',
 u'GP': u'NR',
 u'RANK_PG_MIN': 6,
 u'RANK_FG3_PCT': 35,
 u'SEASON_ID': u'2015-16',
 u'RANK_PG_AST': 3,
 u'RANK_PG_BLK': 16,
 u'RANK_PG_TOV': 5,
 u'RANK_PG_FGM': 1,
 u'RANK_FT_PCT': 46,
 u'RANK_FG_PCT': 6,
 u'RANK_PG_FGA': 1
}]

player_profile.next_game()

player_profile = player.PlayerProfile("2544")
print(player_profile.next_game())

[{
 u'DATE_EST': u'2016-12-10T00:00:00',
 u'STAT': u'PTS',
 u'VS_TEAM_NAME': u'Hornets',
 u'VS_TEAM_CITY': u'Charlotte',
 u'GAME_DATE': u'DEC 10 2016',
 u'VS_TEAM_ABBREVIATION': u'CHA',
 u'STAT_ORDER': 1,
 u'PLAYER_ID': 2544,
 u'GAME_ID': u'0021600349',
 u'VS_TEAM_ID': 1610612766,
 u'STAT_VALUE': 44
 },...
 {
 u'DATE_EST': u'2016-12-07T00:00:00',
 u'STAT': u'FTA',
 u'VS_TEAM_NAME': u'Knicks',
 u'VS_TEAM_CITY': u'New York',
 u'GAME_DATE': u'DEC 07 2016',
 u'VS_TEAM_ABBREVIATION': u'NYK',
 u'STAT_ORDER': 13,
 u'PLAYER_ID': 2544,
 u'GAME_ID': u'0021600327',
 u'VS_TEAM_ID': 1610612752,
 u'STAT_VALUE': 14
}]
from nba_py import player – player.PlayerGameLogs() – endpoint: playergamelog
player_id: "2544" (required),
per_mode: "PerGame" (constants.PerMode.Default),
league_id: "00" (constants.League.NBA),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season"

player_game_log.info()

player_game_log = player.PlayerGameLogs("2544")
print(player_game_log.info())

[{
 u'MIN': 44,
 u'WL': u'W',
 u'TOV': 8,
 u'VIDEO_AVAILABLE': 1,
 u'REB': 8,
 u'FG3A': 6,
 u'MATCHUP': u'CLE vs. BOS',
 u'AST': 11,
 u'FG3M': 2,
 u'OREB': 2,
 u'FGM': 9,
 u'PF': 2,
 u'Game_ID': u'0021600488',
 u'PTS': 23,
 u'FGA': 18,
 u'PLUS_MINUS': 1,
 u'STL': 1,
 u'FTA': 7,
 u'Player_ID': 2544,
 u'BLK': 3,
 u'DREB': 6,
 u'FTM': 3,
 u'FT_PCT': 0.429,
 u'SEASON_ID': u'22016',
 u'FG_PCT': 0.5,
 u'FG3_PCT': 0.333,
 u'GAME_DATE': u'DEC 29, 2016'
 },...
 {
 u'MIN': 32,
 u'WL': u'W',
 u'TOV': 4,
 u'VIDEO_AVAILABLE': 1,
 u'REB': 11,
 u'FG3A': 3,
 u'MATCHUP': u'CLE vs. NYK',
 u'AST': 14,
 u'FG3M': 0,
 u'OREB': 3,
 u'FGM': 9,
 u'PF': 3,
 u'Game_ID': u'0021600001',
 u'PTS': 19,
 u'FGA': 14,
 u'PLUS_MINUS': 26,
 u'STL': 0,
 u'FTA': 2,
 u'Player_ID': 2544,
 u'BLK': 1,
 u'DREB': 8,
 u'FTM': 1,
 u'FT_PCT': 0.5,
 u'SEASON_ID': u'22016',
 u'FG_PCT': 0.643,
 u'FG3_PCT': 0.0,
 u'GAME_DATE': u'OCT 25, 2016'
}]
from nba_py import player – player.PlayerShotTracking() – endpoint: playerdashptshots
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_shot_tracking.general_shooting()

player_shot_tracking = player.PlayerShotTracking("2544")
print(player_shot_tracking.general_shooting())

[{
 u'FG3A': 1.86,
 u'FG2A': 0.43,
 u'EFG_PCT': 0.672,
 u'FG3A_FREQUENCY': 0.101,
 u'FG3_PCT': 0.5,
 u'G': 26,
 u'GP': 28,
 u'FG_PCT': 0.469,
 u'FG3M': 0.93,
 u'SHOT_TYPE': u'Catch and Shoot',
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.124,
 u'FGM': 1.07,
 u'FG2_PCT': 0.333,
 u'SORT_ORDER': 1,
 u'FG2M': 0.14,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.023,
 u'FGA': 2.29
 },
 {
 u'FG3A': 2.57,
 u'FG2A': 3.89,
 u'EFG_PCT': 0.387,
 u'FG3A_FREQUENCY': 0.14,
 u'FG3_PCT': 0.278,
 u'G': 27,
 u'GP': 28,
 u'FG_PCT': 0.331,
 u'FG3M': 0.71,
 u'SHOT_TYPE': u'Pull Ups',
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.351,
 u'FGM': 2.14,
 u'FG2_PCT': 0.367,
 u'SORT_ORDER': 2,
 u'FG2M': 1.43,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.212,
 u'FGA': 6.46
 },
 {
 u'FG3A': 0.0,
 u'FG2A': 8.93,
 u'EFG_PCT': 0.668,
 u'FG3A_FREQUENCY': 0.0,
 u'FG3_PCT': None,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.668,
 u'FG3M': 0.0,
 u'SHOT_TYPE': u'Less than 10 ft',
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.485,
 u'FGM': 5.96,
 u'FG2_PCT': 0.668,
 u'SORT_ORDER': 3,
 u'FG2M': 5.96,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.485,
 u'FGA': 8.93
 },
 {
 u'FG3A': 0.5,
 u'FG2A': 0.21,
 u'EFG_PCT': 0.5,
 u'FG3A_FREQUENCY': 0.027,
 u'FG3_PCT': 0.429,
 u'G': 13,
 u'GP': 28,
 u'FG_PCT': 0.35,
 u'FG3M': 0.21,
 u'SHOT_TYPE': u'Other',
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.039,
 u'FGM': 0.25,
 u'FG2_PCT': 0.167,
 u'SORT_ORDER': 4,
 u'FG2M': 0.04,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.012,
 u'FGA': 0.71
}]

player_shot_tracking.shot_clock_shooting()

player_shot_tracking = player.PlayerShotTracking("2544")
print(player_shot_tracking.shot_clock_shooting())

[{
 u'FG3A': 0.04,
 u'FG2A': 0.71,
 u'EFG_PCT': 0.738,
 u'FG3A_FREQUENCY': 0.002,
 u'FG3_PCT': 1.0,
 u'G': 14,
 u'GP': 28,
 u'FG_PCT': 0.714,
 u'FG3M': 0.04,
 u'FG2M': 0.5,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.041,
 u'FGM': 0.54,
 u'FG2_PCT': 0.7,
 u'SORT_ORDER': 1,
 u'PLAYER_ID': 2544,
 u'SHOT_CLOCK_RANGE': u'24-22',
 u'FG2A_FREQUENCY': 0.039,
 u'FGA': 0.75
 },...
 {
 u'FG3A': 0.57,
 u'FG2A': 1.61,
 u'EFG_PCT': 0.443,
 u'FG3A_FREQUENCY': 0.031,
 u'FG3_PCT': 0.25,
 u'G': 5,
 u'GP': 28,
 u'FG_PCT': 0.41,
 u'FG3M': 0.14,
 u'FG2M': 0.75,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.118,
 u'FGM': 0.89,
 u'FG2_PCT': 0.467,
 u'SORT_ORDER': 8,
 u'PLAYER_ID': 2544,
 u'SHOT_CLOCK_RANGE': u'Not Captured',
 u'FG2A_FREQUENCY': 0.087,
 u'FGA': 2.18
}]

player_shot_tracking.dribble_shooting()

player_shot_tracking = player.PlayerShotTracking("2544")
print(player_shot_tracking.dribble_shooting())

[{
 u'FG3A': 2.36,
 u'FG2A': 3.11,
 u'EFG_PCT': 0.706,
 u'FG3A_FREQUENCY': 0.128,
 u'FG3_PCT': 0.485,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.601,
 u'FG3M': 1.14,
 u'FG2M': 2.14,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.297,
 u'FGM': 3.29,
 u'FG2_PCT': 0.69,
 u'SORT_ORDER': 1,
 u'DRIBBLE_RANGE': u'0 Dribbles',
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.169,
 u'FGA': 5.46
 },...
 {
 u'FG3A': 1.04,
 u'FG2A': 3.25,
 u'EFG_PCT': 0.504,
 u'FG3A_FREQUENCY': 0.056,
 u'FG3_PCT': 0.241,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.475,
 u'FG3M': 0.25,
 u'FG2M': 1.79,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.233,
 u'FGM': 2.04,
 u'FG2_PCT': 0.549,
 u'SORT_ORDER': 5,
 u'DRIBBLE_RANGE': u'7+ Dribbles',
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.177,
 u'FGA': 4.29
}]

player_shot_tracking.closest_defender_shooting()

player_shot_tracking = player.PlayerShotTracking("2544")
print(player_shot_tracking.closest_defender_shooting())

[{
 u'FG3A': 0.0,
 u'FG2A': 2.75,
 u'EFG_PCT': 0.558,
 u'FG3A_FREQUENCY': 0.0,
 u'FG3_PCT': None,
 u'G': 24,
 u'GP': 28,
 u'FG_PCT': 0.558,
 u'FG3M': 0.0,
 u'FG2M': 1.54,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.15,
 u'CLOSE_DEF_DIST_RANGE': u'0-2 Feet - Very Tight',
 u'FG2_PCT': 0.558,
 u'SORT_ORDER': 1,
 u'FGM': 1.54,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.15,
 u'FGA': 2.75
 },
 {
 u'FG3A': 0.89,
 u'FG2A': 6.25,
 u'EFG_PCT': 0.543,
 u'FG3A_FREQUENCY': 0.049,
 u'FG3_PCT': 0.2,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.53,
 u'FG3M': 0.18,
 u'FG2M': 3.61,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.388,
 u'CLOSE_DEF_DIST_RANGE': u'2-4 Feet - Tight',
 u'FG2_PCT': 0.577,
 u'SORT_ORDER': 2,
 u'FGM': 3.79,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.34,
 u'FGA': 7.14
 },
 {
 u'FG3A': 2.18,
 u'FG2A': 3.68,
 u'EFG_PCT': 0.546,
 u'FG3A_FREQUENCY': 0.118,
 u'FG3_PCT': 0.41,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.47,
 u'FG3M': 0.89,
 u'FG2M': 1.86,
 u'PLAYER_NAME_LAST_FIRST': u'James,
 LeBron',
 u'FGA_FREQUENCY': 0.318,
 u'CLOSE_DEF_DIST_RANGE': u'4-6 Feet - Open',
 u'FG2_PCT': 0.505,
 u'SORT_ORDER': 3,
 u'FGM': 2.75,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.2,
 u'FGA': 5.86
 },
 {
 u'FG3A': 1.86,
 u'FG2A': 0.79,
 u'EFG_PCT': 0.662,
 u'FG3A_FREQUENCY': 0.101,
 u'FG3_PCT': 0.423,
 u'G': 26,
 u'GP': 28,
 u'FG_PCT': 0.514,
 u'FG3M': 0.79,
 u'FG2M': 0.57,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGA_FREQUENCY': 0.144,
 u'CLOSE_DEF_DIST_RANGE': u'6+ Feet - Wide Open',
 u'FG2_PCT': 0.727,
 u'SORT_ORDER': 4,
 u'FGM': 1.36,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.043,
 u'FGA': 2.64
}]

player_shot_tracking.closest_defender_shooting_long()

player_shot_tracking = player.PlayerShotTracking("2544")
print(player_shot_tracking.closest_defender_shooting_long())

[{
 u'FG3A': 0.0,
 u'FG2A': 0.11,
 u'EFG_PCT': 1.0,
 u'FG3A_FREQUENCY': 0.0,
 u'FG3_PCT': None,
 u'G': 3,
 u'GP': 28,
 u'FG_PCT': 1.0,
 u'FG3M': 0.0,
 u'FG2M': 0.11,
 u'PLAYER_NAME_LAST_FIRST': u'James, Lebron',
 u'FGA_FREQUENCY': 0.006,
 u'CLOSE_DEF_DIST_RANGE': u'0-2 Feet - Very Tight',
 u'FG2_PCT': 1.0,
 u'SORT_ORDER': 1,
 u'FGM': 0.11,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.006,
 u'FGA': 0.11
 },
 {
 u'FG3A': 0.89,
 u'FG2A': 1.68,
 u'EFG_PCT': 0.299,
 u'FG3A_FREQUENCY': 0.049,
 u'FG3_PCT': 0.2,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.264,
 u'FG3M': 0.18,
 u'FG2M': 0.5,
 u'PLAYER_NAME_LAST_FIRST': u'James, Lebron',
 u'FGA_FREQUENCY': 0.14,
 u'CLOSE_DEF_DIST_RANGE': u'2-4 Feet - Tight',
 u'FG2_PCT': 0.298,
 u'SORT_ORDER': 2,
 u'FGM': 0.68,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.091,
 u'FGA': 2.57
 },
 {
 u'FG3A': 2.18,
 u'FG2A': 2.46,
 u'EFG_PCT': 0.481,
 u'FG3A_FREQUENCY': 0.118,
 u'FG3_PCT': 0.41,
 u'G': 27,
 u'GP': 28,
 u'FG_PCT': 0.385,
 u'FG3M': 0.89,
 u'FG2M': 0.89,
 u'PLAYER_NAME_LAST_FIRST': u'James, Lebron',
 u'FGA_FREQUENCY': 0.252,
 u'CLOSE_DEF_DIST_RANGE': u'4-6 Feet - Open',
 u'FG2_PCT': 0.362,
 u'SORT_ORDER': 3,
 u'FGM': 1.79,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.134,
 u'FGA': 4.64
 },
 {
 u'FG3A': 1.86,
 u'FG2A': 0.29,
 u'EFG_PCT': 0.6,
 u'FG3A_FREQUENCY': 0.101,
 u'FG3_PCT': 0.423,
 u'G': 24,
 u'GP': 28,
 u'FG_PCT': 0.417,
 u'FG3M': 0.79,
 u'FG2M': 0.11,
 u'PLAYER_NAME_LAST_FIRST': u'James, Lebron',
 u'FGA_FREQUENCY': 0.117,
 u'CLOSE_DEF_DIST_RANGE': u'6+ Feet - Wide Open',
 u'FG2_PCT': 0.375,
 u'SORT_ORDER': 4,
 u'FGM': 0.89,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.016,
 u'FGA': 2.14
}]

player_shot_tracking.touch_time_shooting()

player_shot_tracking = player.PlayerShotTracking("2544")
print(player_shot_tracking.touch_time_shooting())

[{
 u'FGA': 5.32,
 u'FG3A': 1.89,
 u'FG2A': 3.43,
 u'EFG_PCT': 0.738,
 u'FG3A_FREQUENCY': 0.103,
 u'FG3_PCT': 0.491,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.651,
 u'FG3M': 0.93,
 u'FG2M': 2.54,
 u'PLAYER_NAME_LAST_FIRST': u'James, Lebron',
 u'FGA_FREQUENCY': 0.289,
 u'FGM': 3.46,
 u'FG2_PCT': 0.74,
 u'SORT_ORDER': 1,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.186,
 u'TOUCH_TIME_RANGE': u'Touch < 2 Seconds'
 },
 {
 u'FGA': 7.14,
 u'FG3A': 1.57,
 u'FG2A': 5.57,
 u'EFG_PCT': 0.498,
 u'FG3A_FREQUENCY': 0.085,
 u'FG3_PCT': 0.295,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.465,
 u'FG3M': 0.46,
 u'FG2M': 2.86,
 u'PLAYER_NAME_LAST_FIRST': u'James, Lebron',
 u'FGA_FREQUENCY': 0.388,
 u'FGM': 3.32,
 u'FG2_PCT': 0.513,
 u'SORT_ORDER': 2,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.303,
 u'TOUCH_TIME_RANGE': u'Touch 2-6 Seconds'
 },
 {
 u'FGA': 5.93,
 u'FG3A': 1.46,
 u'FG2A': 4.46,
 u'EFG_PCT': 0.485,
 u'FG3A_FREQUENCY': 0.08,
 u'FG3_PCT': 0.317,
 u'G': 28,
 u'GP': 28,
 u'FG_PCT': 0.446,
 u'FG3M': 0.46,
 u'FG2M': 2.18,
 u'PLAYER_NAME_LAST_FIRST': u'James, Lebron',
 u'FGA_FREQUENCY': 0.322,
 u'FGM': 2.64,
 u'FG2_PCT': 0.488,
 u'SORT_ORDER': 3,
 u'PLAYER_ID': 2544,
 u'FG2A_FREQUENCY': 0.243,
 u'TOUCH_TIME_RANGE': u'Touch 6+ Seconds'
}]
from nba_py import player – player.PlayerReboundTracking() – endpoint: playerdashptreb
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_rebound_tracking.shot_type_rebounding()

player_rebound_tracking = player.PlayerReboundTracking("2544")
print(player_rebound_tracking.shot_type_rebounding())

[{
 u'UC_OREB': 0.0,
 u'G': 28,
 u'SHOT_TYPE_RANGE': u'Miss FTA',
 u'C_OREB': 0.07,
 u'C_DREB': 0.04,
 u'C_REB_PCT': 0.25,
 u'OREB': 0.07,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 0.32,
 u'REB': 0.43,
 u'SORT_ORDER': 1,
 u'C_REB': 0.11,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.054,
 u'DREB': 0.36,
 u'UC_REB_PCT': 0.75,
 u'UC_DREB': 0.32
 },
 {
 u'UC_OREB': 0.18,
 u'G': 28,
 u'SHOT_TYPE_RANGE': u'Miss 2FG',
 u'C_OREB': 0.5,
 u'C_DREB': 0.64,
 u'C_REB_PCT': 0.26,
 u'OREB': 0.68,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 3.25,
 u'REB': 4.39,
 u'SORT_ORDER': 2,
 u'C_REB': 1.14,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.554,
 u'DREB': 3.71,
 u'UC_REB_PCT': 0.74,
 u'UC_DREB': 3.07
 },
 {
 u'UC_OREB': 0.32,
 u'G': 28,
 u'SHOT_TYPE_RANGE': u'Miss 3FG',
 u'C_OREB': 0.32,
 u'C_DREB': 0.32,
 u'C_REB_PCT': 0.207,
 u'OREB': 0.64,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 2.46,
 u'REB': 3.11,
 u'SORT_ORDER': 3,
 u'C_REB': 0.64,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.392,
 u'DREB': 2.46,
 u'UC_REB_PCT': 0.793,
 u'UC_DREB': 2.14
}]

player_rebound_tracking.num_contested_rebounding()

player_rebound_tracking = player.PlayerReboundTracking("2544")
print(player_rebound_tracking.num_contested_rebounding())

[{
 u'UC_OREB': 0.5,
 u'REB_NUM_CONTESTING_RANGE': u'0 Contesting Rebounders',
 u'G': 28,
 u'C_OREB': 0.0,
 u'C_DREB': 0.0,
 u'C_REB_PCT': 0.0,
 u'OREB': 0.5,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 6.04,
 u'REB': 6.04,
 u'SORT_ORDER': 1,
 u'C_REB': 0.0,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.761,
 u'DREB': 5.54,
 u'UC_REB_PCT': 1.0,
 u'UC_DREB': 5.54
 },
 {
 u'UC_OREB': 0.0,
 u'REB_NUM_CONTESTING_RANGE': u'1 Contesting Rebounder',
 u'G': 28,
 u'C_OREB': 0.71,
 u'C_DREB': 0.89,
 u'C_REB_PCT': 1.0,
 u'OREB': 0.71,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 0.0,
 u'REB': 1.61,
 u'SORT_ORDER': 2,
 u'C_REB': 1.61,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.203,
 u'DREB': 0.89,
 u'UC_REB_PCT': 0.0,
 u'UC_DREB': 0.0
 },
 {
 u'UC_OREB': 0.0,
 u'REB_NUM_CONTESTING_RANGE': u'2+ Contesting Rebounders',
 u'G': 28,
 u'C_OREB': 0.18,
 u'C_DREB': 0.11,
 u'C_REB_PCT': 1.0,
 u'OREB': 0.18,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 0.0,
 u'REB': 0.29,
 u'SORT_ORDER': 3,
 u'C_REB': 0.29,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.036,
 u'DREB': 0.11,
 u'UC_REB_PCT': 0.0,
 u'UC_DREB': 0.0}]

player_rebound_tracking.shot_distance_rebounding()

player_rebound_tracking = player.PlayerReboundTracking("2544")
print(player_rebound_tracking.shot_distance_rebounding())

[{
 u'UC_OREB': 0.07,
 u'G': 28,
 u'C_OREB': 0.29,
 u'C_DREB': 0.25,
 u'C_REB_PCT': 0.395,
 u'OREB': 0.36,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 0.82,
 u'REB': 1.36,
 u'SHOT_DIST_RANGE': u'0-6 Feet',
 u'SORT_ORDER': 1,
 u'C_REB': 0.54,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.171,
 u'DREB': 1.0,
 u'UC_REB_PCT': 0.605,
 u'UC_DREB': 0.75
 },
 {
 u'UC_OREB': 0.07,
 u'G': 28,
 u'C_OREB': 0.14,
 u'C_DREB': 0.21,
 u'C_REB_PCT': 0.233,
 u'OREB': 0.21,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 1.18,
 u'REB': 1.54,
 u'SHOT_DIST_RANGE': u'7-13 Feet',
 u'SORT_ORDER': 2,
 u'C_REB': 0.36,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.194,
 u'DREB': 1.32,
 u'UC_REB_PCT': 0.767,
 u'UC_DREB': 1.11
 },
 {
 u'UC_OREB': 0.0,
 u'G': 28,
 u'C_OREB': 0.14,
 u'C_DREB': 0.11,
 u'C_REB_PCT': 0.2,
 u'OREB': 0.14,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 1.0,
 u'REB': 1.25,
 u'SHOT_DIST_RANGE': u'13-19 Feet',
 u'SORT_ORDER': 3,
 u'C_REB': 0.25,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.158,
 u'DREB': 1.11,
 u'UC_REB_PCT': 0.8,
 u'UC_DREB': 1.0
 },
 {
 u'UC_OREB': 0.36,
 u'G': 28,
 u'C_OREB': 0.32,
 u'C_DREB': 0.43,
 u'C_REB_PCT': 0.198,
 u'OREB': 0.68,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'UC_REB': 3.04,
 u'REB': 3.79,
 u'SHOT_DIST_RANGE': u'19+ Feet',
 u'SORT_ORDER': 4,
 u'C_REB': 0.75,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.477,
 u'DREB': 3.11,
 u'UC_REB_PCT': 0.802,
 u'UC_DREB': 2.68
}]

player_rebound_tracking.rebound_distance_rebounding()

player_rebound_tracking = player.PlayerReboundTracking("2544")
print(player_rebound_tracking.rebound_distance_rebounding())

[{
 u'UC_OREB': 0.04,
 u'G': 28,
 u'C_OREB': 0.39,
 u'C_DREB': 0.39,
 u'C_REB_PCT': 0.44,
 u'OREB': 0.43,
 u'PLAYER_NAME_LAST_FIRST': u'James,
 LeBron',
 u'UC_REB': 1.0,
 u'REB': 1.79,
 u'SORT_ORDER': 1,
 u'REB_DIST_RANGE': u'0-3 Feet',
 u'C_REB': 0.79,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.225,
 u'DREB': 1.36,
 u'UC_REB_PCT': 0.56,
 u'UC_DREB': 0.96
 },
 {
 u'UC_OREB': 0.07,
 u'G': 28,
 u'C_OREB': 0.25,
 u'C_DREB': 0.46,
 u'C_REB_PCT': 0.294,
 u'OREB': 0.32,
 u'PLAYER_NAME_LAST_FIRST': u'James,
 LeBron',
 u'UC_REB': 1.71,
 u'REB': 2.43,
 u'SORT_ORDER': 2,
 u'REB_DIST_RANGE': u'3-6 Feet',
 u'C_REB': 0.71,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.306,
 u'DREB': 2.11,
 u'UC_REB_PCT': 0.706,
 u'UC_DREB': 1.64
 },
 {
 u'UC_OREB': 0.0,
 u'G': 28,
 u'C_OREB': 0.25,
 u'C_DREB': 0.14,
 u'C_REB_PCT': 0.177,
 u'OREB': 0.25,
 u'PLAYER_NAME_LAST_FIRST': u'James,
 LeBron',
 u'UC_REB': 1.82,
 u'REB': 2.21,
 u'SORT_ORDER': 3,
 u'REB_DIST_RANGE': u'6-10 Feet',
 u'C_REB': 0.39,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.279,
 u'DREB': 1.96,
 u'UC_REB_PCT': 0.823,
 u'UC_DREB': 1.82
 },
 {
 u'UC_OREB': 0.39,
 u'G': 28,
 u'C_OREB': 0.0,
 u'C_DREB': 0.0,
 u'C_REB_PCT': 0.0,
 u'OREB': 0.39,
 u'PLAYER_NAME_LAST_FIRST': u'James,
 LeBron',
 u'UC_REB': 1.5,
 u'REB': 1.5,
 u'SORT_ORDER': 4,
 u'REB_DIST_RANGE': u'10+ Feet',
 u'C_REB': 0.0,
 u'PLAYER_ID': 2544,
 u'REB_FREQUENCY': 0.189,
 u'DREB': 1.11,
 u'UC_REB_PCT': 1.0,
 u'UC_DREB': 1.11
}]
from nba_py import player – player.PlayerPassTracking() – endpoint: playerdashptpass
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_pass_tracking.passes_made()

player_pass_tracking = player.PlayerPassTracking("2544")
print(player_pass_tracking.passes_made())

[{
 u'FGA': 0.14,
 u'FG3A': 0.04,
 u'FG2A': 0.11,
 u'FG_PCT': 0.0,
 u'FG3_PCT': 0.0,
 u'G': 28,
 u'AST': 0.0,
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG2_PCT': 0.0,
 u'FG2M': 0.0,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGM': 0.0,
 u'TEAM_ID': 1610612739,
 u'FREQUENCY': 0.007,
 u'FG3M': 0.0,
 u'PASS': 0.43,
 u'PLAYER_ID': 2544,
 u'PASS_TEAMMATE_PLAYER_ID': 1627770,
 u'TEAM_NAME': u'Cleveland Cavaliers',
 u'PASS_TO': u'Felder, Kay',
 u'PASS_TYPE': u'made'
 },...
 {
 u'FGA': 1.39,
 u'FG3A': 0.75,
 u'FG2A': 0.64,
 u'FG_PCT': 0.385,
 u'FG3_PCT': 0.19,
 u'G': 28,
 u'AST': 0.5,
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG2_PCT': 0.611,
 u'FG2M': 0.39,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGM': 0.54,
 u'TEAM_ID': 1610612739,
 u'FREQUENCY': 0.064,
 u'FG3M': 0.14,
 u'PASS': 3.64,
 u'PLAYER_ID': 2544,
 u'PASS_TEAMMATE_PLAYER_ID': 2210,
 u'TEAM_NAME': u'Cleveland Cavaliers',
 u'PASS_TO': u'Jefferson, Richard',
 u'PASS_TYPE': u'made'
}]

player_pass_tracking.passes_received()

player_pass_tracking = player.PlayerPassTracking("2544")
print(player_pass_tracking.passes_received())

[{
 u'FG3A': 0.11,
 u'FG2A': 0.11,
 u'PASS_FROM': u'Felder, Kay',
 u'FG3_PCT': 0.333,
 u'G': 28,
 u'AST': 0.0,
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG2_PCT': 0.333,
 u'FG2M': 0.04,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGM': 0.07,
 u'TEAM_ID': 1610612739,
 u'FREQUENCY': 0.012,
 u'FG3M': 0.04,
 u'PASS': 0.82,
 u'PLAYER_ID': 2544,
 u'PASS_TEAMMATE_PLAYER_ID': 1627770,
 u'TEAM_NAME': u'Cleveland Cavaliers',
 u'FG_PCT': 0.333,
 u'FGA': 0.21,
 u'PASS_TYPE': u'received'
 },...
 {
 u'FG3A': 0.25,
 u'FG2A': 1.04,
 u'PASS_FROM': u'Jefferson, Richard',
 u'FG3_PCT': 0.286,
 u'G': 28,
 u'AST': 0.29,
 u'TEAM_ABBREVIATION': u'CLE',
 u'FG2_PCT': 0.586,
 u'FG2M': 0.61,
 u'PLAYER_NAME_LAST_FIRST': u'James, LeBron',
 u'FGM': 0.68,
 u'TEAM_ID': 1610612739,
 u'FREQUENCY': 0.075,
 u'FG3M': 0.07,
 u'PASS': 5.18,
 u'PLAYER_ID': 2544,
 u'PASS_TEAMMATE_PLAYER_ID': 2210,
 u'TEAM_NAME': u'Cleveland Cavaliers',
 u'FG_PCT': 0.528,
 u'FGA': 1.29,
 u'PASS_TYPE': u'received'
}]
from nba_py import player – player.PlayerDefenseTracking() – endpoint: playerdashptshotdefend
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

no available functions yet

from nba_py import player – player.PlayerShotLogTracking() – endpoint: playerdashptshotlog
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

no available functions yet

from nba_py import player – player.PlayerReboundLogTracking() – endpoint: playerdashptreboundlogs
player_id: "2544" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

no available functions yet

from nba_py import player – player.PlayervsPlayer() – endpoint: playervsplayer
player_id: "2544" (required),
vs_player_id: "201939" (required),
team_id: 0 (default),
measure_type: "Base" (constants.MeasureType.Default),
per_mode: "PerGame" (constants.PerMode.Default),
plus_minus: "N" (constants.PlusMinus.Default),
pace_adjust: "N" (constants.PaceAdjust.Default),
rank: "N" (constants.PaceAdjust.Default),
league_id: "00" (constants.League.Default),
season: "2016-17" (constants.CURRENT_SEASON),
season_type: "Regular Season" (constants.SeasonType.Default),
po_round: "0" (constants.PlayoffRound.Default),
outcome: "" (constants.Outcome.Default),
location: "" (constants.Location.Default),
month: "0" (constants.Month.Default),
season_segment: "" (constants.SeasonSegment.Default),
date_from: "" (constants.DateFrom.Default),
date_to: "" (constants.DateTo.Default),
opponent_team_id: "0" (constants.OpponentTeamID.Default),
vs_conference: "" (constants.VsConference.Default),
vs_division: "" (constants.VsDivision.Default),
game_segment: "" (constants.GameSegment.Default),
period: "" (constants.Period.Default),
shot_clock_range: "" (constants.ShotClockRange.Default),
last_n_games: "0" (constants.LastNGames.Default)

player_vs_player.overall()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.overall())

[{
 u'BLK': 0.6,
 u'MIN': 37.1,
 u'TOV': 3.9,
 u'REB': 7.9,
 u'GROUP_VALUE': u'LeBron James',
 u'PLAYER_ID': 2544,
 u'FG3A': 4.9,
 u'PLAYER_NAME': u'LeBron James',
 u'AST': 8.6,
 u'PLUS_MINUS': 10.5,
 u'FG3M': 1.9,
 u'OREB': 1.4,
 u'FGM': 9.4,
 u'PF': 1.6,
 u'PTS': 25.4,
 u'FGA': 18.4,
 u'GP': 28,
 u'STL': 1.4,
 u'CFPARAMS': u'LeBron James',
 u'L': 4,
 u'FTA': 6.9,
 u'W': 24,
 u'W_PCT': 0.857,
 u'DREB': 6.5,
 u'FTM': 4.7,
 u'FT_PCT': 0.679,
 u'PFD': 5.4,
 u'FG_PCT': 0.513,
 u'CFID': 85,
 u'GROUP_SET': u'Overall',
 u'FG3_PCT': 0.377,
 u'BLKA': 0.8
 },
 {
 u'BLK': 0.1,
 u'MIN': 33.2,
 u'TOV': 2.7,
 u'REB': 4.2,
 u'GROUP_VALUE': u'Stephen Curry',
 u'PLAYER_ID': 201939,
 u'FG3A': 9.2,
 u'PLAYER_NAME': u'Stephen Curry',
 u'AST': 5.9,
 u'PLUS_MINUS': 12.4,
 u'FG3M': 3.7,
 u'OREB': 0.6,
 u'FGM': 7.8,
 u'PF': 2.5,
 u'PTS': 23.9,
 u'FGA': 16.7,
 u'GP': 34,
 u'STL': 1.7,
 u'CFPARAMS': u'Stephen Curry',
 u'L': 5,
 u'FTA': 5.0,
 u'W': 29,
 u'W_PCT': 0.853,
 u'DREB': 3.6,
 u'FTM': 4.7,
 u'FT_PCT': 0.936,
 u'PFD': 3.9,
 u'FG_PCT': 0.466,
 u'CFID': 85,
 u'GROUP_SET': u'Overall',
 u'FG3_PCT': 0.403,
 u'BLKA': 0.6
}]

player_vs_player.on_off_court()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.on_off_court())

[{
 u'BLK': 1.0,
 u'MIN': 34.8,
 u'VS_PLAYER_ID': 201939,
 u'TOV': 5.0,
 u'VS_PLAYER_NAME': u'Curry,
 Stephen',
 u'REB': 10.0,
 u'PLAYER_ID': 2544,
 u'FG3A': 7.0,
 u'PLAYER_NAME': u'LeBron James',
 u'AST': 2.0,
 u'PLUS_MINUS': 5.0,
 u'FG3M': 4.0,
 u'OREB': 3.0,
 u'FGM': 12.0,
 u'PF': 2.0,
 u'PTS': 30.0,
 u'FGA': 20.0,
 u'GP': 1,
 u'STL': 2.0,
 u'CFPARAMS': u'201939',
 u'L': 0,
 u'FTA': 5.0,
 u'W': 1,
 u'W_PCT': 1.0,
 u'DREB': 7.0,
 u'FTM': 2.0,
 u'FT_PCT': 0.4,
 u'PFD': 4.0,
 u'FG_PCT': 0.6,
 u'CFID': 86,
 u'GROUP_SET': u'Vs. Player',
 u'FG3_PCT': 0.571,
 u'COURT_STATUS': u'On',
 u'BLKA': 1.0
 },
 {
 u'BLK': 0.0,
 u'MIN': 5.4,
 u'VS_PLAYER_ID': 201939,
 u'TOV': 0.0,
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'REB': 3.0,
 u'PLAYER_ID': 2544,
 u'FG3A': 1.0,
 u'PLAYER_NAME': u'LeBron James',
 u'AST': 2.0,
 u'PLUS_MINUS': -1.0,
 u'FG3M': 0.0,
 u'OREB': 2.0,
 u'FGM': 0.0,
 u'PF': 0.0,
 u'PTS': 1.0,
 u'FGA': 2.0,
 u'GP': 1,
 u'STL': 0.0,
 u'CFPARAMS': u'201939',
 u'L': 0,
 u'FTA': 2.0,
 u'W': 1,
 u'W_PCT': 1.0,
 u'DREB': 1.0,
 u'FTM': 1.0,
 u'FT_PCT': 0.5,
 u'PFD': 2.0,
 u'FG_PCT': 0.0,
 u'CFID': 87,
 u'GROUP_SET': u'Vs. Player',
 u'FG3_PCT': 0.0,
 u'COURT_STATUS': u'Off',
 u'BLKA': 0.0
}]

player_vs_player.shot_distance_overall()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.shot_distance_overall())

[{
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.735,
 u'CFID': 127,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 5.5,
 u'GROUP_VALUE': u'Less Than 5 ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 7.5
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.267,
 u'CFID': 128,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 0.4,
 u'GROUP_VALUE': u'5-9 ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 1.6
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.367,
 u'CFID': 129,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 0.6,
 u'GROUP_VALUE': u'10-14 ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 1.8
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.457,
 u'CFID': 130,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 0.8,
 u'GROUP_VALUE': u'15-19 ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 1.6
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.339,
 u'CFID': 131,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 0.8,
 u'GROUP_VALUE': u'20-24 ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 2.2
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.354,
 u'CFID': 132,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 1.2,
 u'GROUP_VALUE': u'25-29 ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 3.4
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.6,
 u'CFID': 133,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 0.3,
 u'GROUP_VALUE': u'30-34 ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 0.4
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.0,
 u'CFID': 134,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'35-39 ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.0,
 u'CFID': 135,
 u'GROUP_SET': u'Shot Distance (5ft)',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'40+ ft.',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
}]

player_vs_player.shot_distance_on_court()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.shot_distance_on_court())

[{
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.615,
 u'CFID': 118,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 8.0,
 u'GROUP_VALUE': u'Less Than 5 ft.',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 13.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 119,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'5-9 ft.',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 120,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'10-14 ft.',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 121,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'15-19 ft.',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.5,
 u'CFID': 122,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 1.0,
 u'GROUP_VALUE': u'20-24 ft.',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 2.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.6,
 u'CFID': 123,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 3.0,
 u'GROUP_VALUE': u'25-29 ft.',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 5.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 124,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'30-34 ft.',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 126,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'40+ ft.',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
}]

player_vs_player.shot_distance_off_court()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.shot_distance_off_court())

[{
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 109,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Less Than 5 ft.',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 1.0
 },
 {u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 110,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'5-9 ft.',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 111,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'10-14 ft.',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 112,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'15-19 ft.',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 113,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'20-24 ft.',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 1.0
 },
 {u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 114,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'25-29 ft.',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
}]

player_vs_player.shot_area_overall()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.shot_area_overall())

[{
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.739,
 u'CFID': 102,
 u'GROUP_SET': u'Shot Area',
 u'FGM': 5.4,
 u'GROUP_VALUE': u'Restricted Area',
 u'PLAYER_ID': 2544,
 u'FGA': 7.3
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.351,
 u'CFID': 103,
 u'GROUP_SET': u'Shot Area',
 u'FGM': 0.7,
 u'GROUP_VALUE': u'In The Paint (Non-RA)',
 u'PLAYER_ID': 2544,
 u'FGA': 2.0
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.359,
 u'CFID': 104,
 u'GROUP_SET': u'Shot Area',
 u'FGM': 1.5,
 u'GROUP_VALUE': u'Mid-Range',
 u'PLAYER_ID': 2544,
 u'FGA': 4.2
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.556,
 u'CFID': 105,
 u'GROUP_SET': u'Shot Area',
 u'FGM': 0.2,
 u'GROUP_VALUE': u'Left Corner 3',
 u'PLAYER_ID': 2544,
 u'FGA': 0.3
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.333,
 u'CFID': 106,
 u'GROUP_SET': u'Shot Area',
 u'FGM': 0.1,
 u'GROUP_VALUE': u'Right Corner 3',
 u'PLAYER_ID': 2544,
 u'FGA': 0.4
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.371,
 u'CFID': 107,
 u'GROUP_SET': u'Shot Area',
 u'FGM': 1.5,
 u'GROUP_VALUE': u'Above the Break 3',
 u'PLAYER_ID': 2544,
 u'FGA': 4.1
 },
 {
 u'CFPARAMS': None,
 u'PLAYER_NAME': u'LeBron James',
 u'FG_PCT': 0.0,
 u'CFID': 108,
 u'GROUP_SET': u'Shot Area',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Backcourt',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
}]

player_vs_player.shot_area_on_court()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.shot_area_on_court())

[{
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.615,
 u'CFID': 95,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 8.0,
 u'GROUP_VALUE': u'Restricted Area',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 13.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 96,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'In The Paint (Non-RA)',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 97,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Mid-Range',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 98,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Left Corner 3',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 1.0,
 u'CFID': 99,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 1.0,
 u'GROUP_VALUE': u'Right Corner 3',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 1.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.5,
 u'CFID': 100,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 3.0,
 u'GROUP_VALUE': u'Above the Break 3',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 6.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 101,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Backcourt',
 u'COURT_STATUS': u'On',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
}]

player_vs_player.shot_area_off_court()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.shot_area_off_court())

[{
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 88,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Restricted Area',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 1.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 89,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'In The Paint (Non-RA)',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 90,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Mid-Range',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 91,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Left Corner 3',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 92,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Right Corner 3',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 1.0
 },
 {
 u'CFPARAMS': u'201939',
 u'PLAYER_NAME': u'LeBron James',
 u'VS_PLAYER_ID': 201939,
 u'FG_PCT': 0.0,
 u'CFID': 93,
 u'GROUP_SET': u'Vs. Player',
 u'VS_PLAYER_NAME': u'Curry, Stephen',
 u'FGM': 0.0,
 u'GROUP_VALUE': u'Above the Break 3',
 u'COURT_STATUS': u'Off',
 u'PLAYER_ID': 2544,
 u'FGA': 0.0
}]

player_vs_player.player_info()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.player_info())

[{
 u'FIRST_NAME': u'LeBron',
 u'LAST_NAME': u'James',
 u'COUNTRY': u'USA',
 u'DISPLAY_FIRST_LAST': u'LeBron James',
 u'SCHOOL': u'St. Vincent-St. Mary HS (OH)',
 u'BIRTHDATE': u'1984-12-30T00:00:00',
 u'DISPLAY_FI_LAST': u'L. James',
 u'PERSON_ID': 2544,
 u'DISPLAY_LAST_COMMA_FIRST': u'James, LeBron',
 u'LAST_AFFILIATION': u'St. Vincent-St. Mary HS (OH)/USA'
}]

player_vs_player.vs_player_info()

player_vs_player = player.PlayerVsPlayer("2544", "201939")
print(player_vs_player.vs_player_info())

[{
 u'FIRST_NAME': u'Stephen',
 u'LAST_NAME': u'Curry',
 u'COUNTRY': u'USA',
 u'DISPLAY_FIRST_LAST': u'Stephen Curry',
 u'SCHOOL': u'Davidson',
 u'BIRTHDATE': u'1988-03-14T00:00:00',
 u'DISPLAY_FI_LAST': u'S. Curry',
 u'PERSON_ID': 201939,
 u'DISPLAY_LAST_COMMA_FIRST': u'Curry,
 Stephen',
 u'LAST_AFFILIATION': u'Davidson/USA'
}]

 

team

For the following player related endpoints, you have to put from nba_py import team.

The rest of the examples will be added on a future date. I’m exhausted!

For now, refer to the official documentation. It doesn’t have any examples though!

How to Access Ubuntu Bash Files from Windows

If you installed Bash on Windows 10, and you want to get access to the files that you created on Bash from the Windows side, here’s what you need to do!

  1. Open File Explorer
  2. Click File on the top left, click Change folder and search options
  3. Click on View tab, make sure Show hidden files, folders, and drives is selected, Click OK
  4. Click on the folder directory address box, copy and paste: %localappdata%\lxss or C:\Users\{username}\AppData\Local\Packages\CanonicalGroupLimited.Ubuntu##.##
  5. When you click Enter, you’ll be in the Bash directory (2017): C:\Users\{username}\AppData\Local\lxss
  6. You can access the files through Cygwin or File Explorer in the future

 

1. Open File Explorer.

 

2. Click File on the top left, click Change folder and search options.

 

3. Click on View tab, make sure Show hidden files, folders, and drives is selected, Click OK.

 

4. (2017) Click on the folder directory address box, copy and paste: %localappdata%\lxss

If you’ve downloaded Ubuntu recently in (2018), then the path is different:

A. Go to C:\Users\{username}\AppData\Local\Packages\

B. Start looking for folder with the Ubuntu version (example): CanonicalGroupLimited.Ubuntu18.04

C. Your final destination will be in the LocalState\rootfs folder:

 

5. When you click Enter, you’ll be in the Bash directory: C:\Users\{username}\AppData\Local\lxss

 

6. You can access the files through Cygwin or File Explorer in the future!

How to Copy to System Clipboard from Vim

In this tutorial, I used Cygwin on Windows 10 and Bash on Windows 10 to copy text from vim to the system clipboard for pasting.

  1. Check if we have +clipboard on our version of vim
  2. If you’re using bash on Windows or Ubuntu, and vim does not have +clipboard, sudo apt-get install vim-gnome -y
  3. +clipboard gets installed
  4. vim file
  5. Type: :%y+ to copy all lines
  6. Right click and paste, and you’ll see the lines you copied from vim

 

Check if we have +clipboard on our version of vim.

vim --version

Instead of -clipboard, we want +clipboard.

 

If you’re using bash or Ubuntu, and vim does not have +clipboard already:

sudo apt-get install vim-gnome -y

 

+clipboard gets installed.

vim --version

 

Open the file with vim and copy its contents to the clipboard.

vim file

Type:

:%y+

to yank all lines.

 

Now, you can right click and paste into a text editor.

I pasted the clipboard to an empty document in Sublime!

How to Script Interactive Programs or TUIs on Python with pexpect

If I had a interactive program or shell like bash, how do I automate and script what I want to do with Python?

There’s a useful pip module called pexpect that you can install.

The idea of pexpect originated from a programming language called Expect that automates interactions with programs that expose a text terminal like ftp, ssh, etc.

Think of any program that opens a session that you have to exit!

Prerequisites

  1. Python 2.7 or Python 3.3 or above
  2. pip install pexpect
  3. If you get lost, read the documentation.

Now, that you have installed pexpect, we can make a simple program as an example.

 

bash example. Sending one command.

Let’s say that I wanted to automate a new session of bash and use ls.

bash works a little differently than other interactive programs since it has a flag that allows input.

  1. You spawn the interactive program with pexpect.spawn("/bin/bash -c ls").
  2. You expect what comes after the command like \r\n (meaning new line) or the next command you know you’ll send.
  3. child.before is all the output before what we expect. We can print or use it in an if clause.

 

ssh example. Knowing what exactly we’re expecting. Sending multiple commands.

bash was a special example since the program allows input with its -c flag.

What if the program doesn’t have such a flag?

Let’s say that I wanted to automate a command on another machine with ssh.

Not just one command. Multiple commands.

Manual
  1. ssh into the machine.
  2. Create a file called slothparadise with touch.
  3. ls the current folder.

Automated

When we use pexpect to automate the manual process, we take a look at what we expect to happen.

We pinpoint what we will see after the command.

For ssh, it’s easy to see that after each command, we see [email protected]:~.

We can use regex or in this case, it’s easy to use the word as it is.

 

regex example

You can expect uncertain output with regex.

If you don’t know what regex is, it is short for regular expression, which matches ranges of characters or words.

Let’s use regex with the ssh example.

Instead of expecting [email protected]:~, we give room for expecting other users like [email protected]:~.

Who knows? The user might be on root!

If you’re not familiar with regex, then I recommend to double-check your regex with this website.

The regex detects the highlighted blue.

  1. We create slothparadise2.
  2. We list the contents of the directory with ls

Instead of the word, I used the regex expression, and it works the same as before.

Those are the basics of pexpect! You can expand on these examples, and you’ll be on your way to scripting those tiresome interactive programs with an easy-to-use language like Python!

Is the HoloLens Development Edition Worth Buying?

Microsoft HoloLens Dev Edition recently became available in several additional countries. I’ve been using the HoloLens since August 2016.

It’s still a development edition, but is the HoloLens Dev Edition worth buying?

Is it worth 3000 dollars? I’m going to focus on my opinions on its usability to best inform you about the device as it is today.

I’m not undermining the great advances and craftsmanship of the device, but I’d like to focus on one thing that I especially care about: long term use.

Long term experiences that you will enjoy.

 

FOV – Field of View

Field of View is one of the biggest limitations about HoloLens. Field of View is what you see when you put on the device.

In a 2015 article by Oliver from doc-ok.org, Oliver measures the Field of Vision to be 30 by 17 degrees. For comparison, the 2016 Oculus and Vive Virtual Reality devices both have 110 degrees for field of view.

The HoloLens does have a 120 by 120 degree camera, and it makes recording the screen easy. All you have to say is: “Hey Cortana, start recording.”

When you see YouTube videos with screen recording of the device, you see the camera’s full 120 by 120 field of vision. Not the 30 by 17 degrees.

Image from Oliver @ http://doc-ok.org/?p=1274

Low Field of View hurts usability. You typically have to focus on one hologram at a time or walk backwards until it fits your Field of Vision.

You can imagine focusing on any enlarged hologram that is bigger than the Field of View. It feels limiting.

Field of view is one of the consistent things that improves with AR and VR devices.

There are options and research on different methods to create these displays.

You can search Light Field Displays. Sparse Peripheral Displays. But as the HoloLens is today, Field of view does not feel great for extended use.

 

Head Mounted Device, Weight, Comfort

HoloLens is completely untethered. No wires. It’s a completely independent device like your laptop or phone. And this feels great!

How heavy is it? 579 grams. For those of you in the United States, it’s about 1.27 pounds. A pair of glasses on the heavier side can weigh 50 grams, meaning about a tenth of a pound.

Think how a bicycle helmet feels on your head. A bicycle helmet like this one can weigh a pound. Could you wear that weight on your head for long extended periods of time?

The HoloLens uses an adjustment wheel to tighten an inner headband around your head. You loosen the inner headband and then tighten it once you put on the device.

You can bring the HoloLens display closer or away from your eyes with the headband. You can wear glasses!

But every now and then, because I could be moving a lot, I found myself readjusting the device a little upward, so that I could see the very top tip of the Field of View better.

You eventually master the inner headband. The headband does feel tight if I want the device to be stable on my head.

Because of the combination of weight and tightness of the inner headband, your forehead and above your ears will get tired, so you won’t feel comfortable using the device for long extended periods of time.

Having the device on your head for 30 minutes and more does not feel 100% comfortable. You’ll almost certainly want to take a break or readjust the device.

 

Controls

You have 5 main controls without any bluetooth device: air tap, gaze, pinch, bloom, and voice commands.

Airtap is where you tap the air. It’s like the left mouse click button on your computer’s mouse.

Gaze is where you aim your head. It’s like moving your mouse on your computer.

Pinch is mainly used like scrolling your mouse.

Bloom is where you touch all your fingers of one hand together and open them outward. It is used to open the start button or exit an application.

Voice commands are reliable.

Air tapping, gaze, and bloom can easily be detected. But pinch can sometimes require a double take.

Controls without a bluetooth device are limiting. You can only do so many things quickly and easily with these 5 control inputs.

The great thing about HoloLens are bluetooth devices. HoloLens comes with a bluetooth clicker, but you can also use bluetooth Xbox One S controller, keyboard, and mouse.

I like having these options. Without using bluetooth devices, the controls and variety of apps are lackluster for using the device for long periods of time. Your arm will get tired bringing it up and down to use the controls.

The bluetooth clicker that comes with the device is a good addition. It does air tapping as a button, hold that button and you’ll do pinching, and pathing, but it’s not always reliable.

 

Image Quality / “Holograms”, Spatial Mapping, 3D audio

Great image quality. Good brightness. Holograms look nice! The device is built for indoor use. Outside, the lighting of the holograms will look different though.

HoloLens will map a room as you look at your surrounding areas. Spatial Mapping is very neat for holograms interacting with the environment.

The apps that take advantage of the spatial mesh of the walls, ceilings, and floor are phenomenal.

Holograms will remain in the same area. If you put a hologram on the table it will still be there when you turn around. Depth works well.

3D audio sounds great. You can hear everything loud and clear. Think of surround sound speakers. The 3D audio on the device immerses you very well.

Another great thing about HoloLens is that you’ll probably not feel nauseous. Augmented reality gives you the benefit of still being able to see real objects, which makes you feel more comfortable.

 

Battery life and specs

Last but not least, battery life can be about 2.5 hours when pushed and used constantly and 4 or I’ve heard even 5 hours when not used intensely.

Don’t worry about battery life because using it for 2.5 hours straight is a stretch.

Power can last in standby mode for 2 weeks. I’ve left my HoloLens in standby for a week, and it was still ready to go.

 

Verdict

There’s 64 GB of Flash Memory, which is great space for apps. The Windows Store doesn’t have many HoloLens apps at the moment, considering that the device is still in development, but installing apps is as easy as it is on a phone.

If you’re a developer and have plans to develop on AR devices like the HoloLens, the device is worth the 3000 dollars.

In the future, HoloLens might be obsolete because a different company like Magic Leap might make a better device, but it won’t matter too much if you’re a developer.

Developers will still likely use similar if not the same 3D engines or game engines to make their applications.

If you have 3000 dollars to spare and only plan on being a user of the device, I don’t think that it’s worth the 3000 dollars. Save your money for the consumer version or rival devices.

I’m looking for good ideas and your opinions on how AR can be better. Do you think that AR will eventually complement your computers and phones as an additional device used daily? What ideas for HoloLens applications or games do you have?

sudo as root X11 connection rejected because of wrong authentication

I received this problem recently when I logged into root on a machine.

X11 connection rejected because of wrong authentication

How did this problem happen? Here’s what I did.

ssh -X [email protected]
sudo su
xclock
X11 connection rejected because of wrong authentication

If I open xclock as a user, then X11 works just fine. As a result, I know that the server and client’s X11 forwarding is working.

A root problem

My .Xauthority and X11 credentials aren’t being passed over to root.

ssh [email protected]
sudo su
xauth merge /home/huyle/.Xauthority
xclock

xclock works, so all I had to do was merge my user’s .Xauthority to root's.

How to Get a User’s Email Address on Github

There are a lot of people (software engineers,  open source compatriots, coding warriors) who contribute to programming projects on Github.

You may be interested in a certain someone on Github, and you need to contact them! Recruiters? Potential partners?

This is the surest way to find someone’s email through Github!

  1. Find the person’s Github username.
  2. Go to a recent Github project that they’ve contributed.
  3. Check the link of a commit message.
  4. Add .patch to the link, and you’ll see the email they used to git commit.

1) Find the person’s Github username

A little Googling should be fruitful.

google-person-github

 

2) Go to a recent Github project that they’ve contributed

We check out the user’s Repositories tab. Click on the repository on the top of the list.

find-a-github-project

Click on # commits.

go-to-github-commits

 

 

3) Check the link of a commit message

Click on the most recent Github commit, which is also a link.

check-most-recent-commit

The commit link is long and has a hash value at the end.

https://github.com/huyle333/huyle333.github.io/commit/e3db62eb93a71112945fe7319aa01125bc6d10e3

regular-github-link

 

4) Add .patch to the link, and you’ll see the email they used to git commit

At the end of the link, add .patch and refresh the page.

https://github.com/huyle333/huyle333.github.io/commit/e3db62eb93a71112945fe7319aa01125bc6d10e3.patch

patch-github-link

You’ll see a new metadata page with an e-mail at the From: section because most users associate their git commits with an e-mail.

email-on-patch-github-link

Eureka!