MCPcopy Index your code
hub / github.com/gonum/plot / CopyXYZs

Function CopyXYZs

plotter/plotter.go:214–223  ·  view source on GitHub ↗

CopyXYZs copies an XYZer.

(data XYZer)

Source from the content-addressed store, hash-verified

212
213// CopyXYZs copies an XYZer.
214func CopyXYZs(data XYZer) (XYZs, error) {
215 cpy := make(XYZs, data.Len())
216 for i := range cpy {
217 cpy[i].X, cpy[i].Y, cpy[i].Z = data.XYZ(i)
218 if err := CheckFloats(cpy[i].X, cpy[i].Y, cpy[i].Z); err != nil {
219 return nil, err
220 }
221 }
222 return cpy, nil
223}
224
225// XYValues implements the XYer interface, returning
226// the x and y values from an XYZer.

Callers

nothing calls this directly

Calls 3

CheckFloatsFunction · 0.85
LenMethod · 0.65
XYZMethod · 0.65

Tested by

no test coverage detected