Skip to content

__init__ methods #5

@diegozea

Description

@diegozea

I started today with PyCall.
I want to test the next.
On Python, I define a Seq object and get the reverse complement using:

from Bio.Seq import Seq
myseq = Seq("AGTACACTGGT")
myseq.reverse_complement()

But, with @pyimport I try and fail with:

julia> using PyCall

julia> @pyimport Bio.Seq as seq

julia> seq.Seq("AGTACACTGGT")
ERROR: type: apply: expected Function, got PyObject

julia> seq.Seq.__init__("AGTACACTGGT")
ERROR: type PyObject has no field __init__

P.S.: I note I can do this, but looks like you can't create a Python Object, only used his methods:

julia> seq.reverse_complement("AGTACACTGGT")
"ACCAGTGTACT"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions