how can i give output of a python file as input to a matlab matrix
1 回表示 (過去 30 日間)
古いコメントを表示
function [] = lanczos(A, m) this is a function i'm using in matlab.
the parameter 'A' is matrix and i want to give input to A from another text file which is output of a python file and has following content(matrix in python)
[[1 2 2 0 0 0 0 0 0 0 0]
[2 1 0 0 0 0 0 0 2 0 0]
[2 0 1 2 0 0 0 0 0 0 0]
[0 0 2 0 2 2 0 0 0 0 0]
[0 0 0 2 0 0 4 0 0 0 0]
[0 0 0 2 0 0 0 2 0 2 0]
[0 0 0 0 4 0 0 2 0 0 0]
[0 0 0 0 0 2 2 0 2 0 0]
[0 2 0 0 0 0 0 2 0 0 2]
[0 0 0 0 0 2 0 0 0 0 4]
[0 0 0 0 0 0 0 0 2 4 0]]
but matrix representation in matlab is different from the content of this file ,so is there a way can i pass this file as input to matrix A in matlab function.
回答 (1 件)
参考
カテゴリ
Help Center および File Exchange で Call Python from MATLAB についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!