Point

Point.py - Extension of QPointF which adds a few missing methods. Copyright 2010 Luke Campagnola Distributed under MIT/X11 license. See license.txt for more information.

Point.length()[source]

Returns the vector length of this Point.

Point.norm()[source]

Returns a vector in the same direction with unit length.

Point.angle(a, units='degrees')[source]

Returns the angle in degrees from the vector a to self.

Parameters
  • a (Point, QPointF or QPoint) – The Point to return the angle with

  • units (str, optional) – The units with which to compute the angle with, “degrees” or “radians”, default “degrees”

Returns

The angle between two vectors

Return type

float

Point.dot(a)[source]

Returns the dot product of a and this Point.

Point.cross(a)[source]
Point.proj(b)[source]

Return the projection of this vector onto the vector b

class pyqtgraph.Point.Point(*args)[source]

Extension of QPointF which adds a few missing methods.

angle(a, units='degrees')[source]

Returns the angle in degrees from the vector a to self.

Parameters
  • a (Point, QPointF or QPoint) – The Point to return the angle with

  • units (str, optional) – The units with which to compute the angle with, “degrees” or “radians”, default “degrees”

Returns

The angle between two vectors

Return type

float

dot(a)[source]

Returns the dot product of a and this Point.

length()[source]

Returns the vector length of this Point.

norm()[source]

Returns a vector in the same direction with unit length.

proj(b)[source]

Return the projection of this vector onto the vector b