Skip to content

width = max([len(line) for c in self._content for line in c]) No content in figure #43

@hudengjunai

Description

@hudengjunai
import termplotlib as tpl
import numpy

x = numpy.linspace(0, 2 * numpy.pi, 10)
y = numpy.sin(x)

fig = tpl.figure()
fig.plot(x, y, label="data", width=50, height=15)
fig.show()

after run this piece of code ,there are error ,

if self._width is None:
---> 33             width = max([len(line) for c in self._content for line in c])
     34             width += padding_lr
     35         else:

did you come up with this problem?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions