package scipy

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Idl.AttrDictSource

Sourcetype tag = [
  1. | `AttrDict
]
Sourcetype t = [ `AttrDict | `Object ] Obj.t
Sourceval of_pyobject : Py.Object.t -> t
Sourceval to_pyobject : [> tag ] Obj.t -> Py.Object.t
Sourceval create : ?init:Py.Object.t -> unit -> t

A case-insensitive dictionary with access via item, attribute, and call notations:

>>> d = AttrDict() >>> d'Variable' = 123 >>> d'Variable' 123 >>> d.Variable 123 >>> d.variable 123 >>> d('VARIABLE') 123

Sourceval __getitem__ : name:Py.Object.t -> [> tag ] Obj.t -> Py.Object.t

x.__getitem__(y) <==> xy

Sourceval __iter__ : [> tag ] Obj.t -> Py.Object.t

Implement iter(self).

Sourceval __setitem__ : key:Py.Object.t -> value:Py.Object.t -> [> tag ] Obj.t -> Py.Object.t

Set selfkey to value.

Sourceval fromkeys : ?value:Py.Object.t -> iterable:Py.Object.t -> [> tag ] Obj.t -> Py.Object.t

Create a new dictionary with keys from iterable and values set to value.

Sourceval get : ?default:Py.Object.t -> key:Py.Object.t -> [> tag ] Obj.t -> Py.Object.t

Return the value for key if key is in the dictionary, else default.

Sourceval pop : ?d:Py.Object.t -> k:Py.Object.t -> [> tag ] Obj.t -> Py.Object.t

D.pop(k,d) -> v, remove specified key and return the corresponding value. If key is not found, d is returned if given, otherwise KeyError is raised

Sourceval popitem : [> tag ] Obj.t -> Py.Object.t

Remove and return a (key, value) pair as a 2-tuple.

Pairs are returned in LIFO (last-in, first-out) order. Raises KeyError if the dict is empty.

Sourceval setdefault : ?default:Py.Object.t -> key:Py.Object.t -> [> tag ] Obj.t -> Py.Object.t

Insert key with a value of default if key is not in the dictionary.

Return the value for key if key is in the dictionary, else default.

Sourceval update : ?e:Py.Object.t -> ?f:(string * Py.Object.t) list -> [> tag ] Obj.t -> Py.Object.t

D.update(E, **F) -> None. Update D from dict/iterable E and F. If E is present and has a .keys() method, then does: for k in E: Dk = Ek If E is present and lacks a .keys() method, then does: for k, v in E: Dk = v In either case, this is followed by: for k in F: Dk = Fk

Sourceval to_string : t -> string

Print the object to a human-readable representation.

Sourceval show : t -> string

Print the object to a human-readable representation.

Sourceval pp : Format.formatter -> t -> unit

Pretty-print the object to a formatter.