io.github.danielTucano.matplotlib.pyplot.title.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of matplotlib4k Show documentation
Show all versions of matplotlib4k Show documentation
Matplotlib for kotlin: A simple graph plot library for kotlin with powerful python matplotlib
The newest version!
package io.github.danielTucano.matplotlib.pyplot
import io.github.danielTucano.extensions.toPythonStringOrNone
import io.github.danielTucano.extensions.toPythonStringQuotedOrEmpty
import io.github.danielTucano.matplotlib.Axes
import io.github.danielTucano.python.PythonScriptBuilder
fun title(label: String = "", loc: Axes.TitleLocationOptions? = null, pad: Float? = null, y: Float? = null) {
PythonScriptBuilder.addCommand(
"plt.title(" +
"${label.toPythonStringQuotedOrEmpty()}," +
"loc=${loc.toPythonStringOrNone()}," +
"pad=${pad.toPythonStringOrNone()}," +
"y=${y.toPythonStringOrNone()}" +
")"
)
}