emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* strange output when executing matlab using babel, strange ,
@ 2019-05-31 13:08 Uwe Brauer
  2019-05-31 13:57 ` John Kitchin
  2019-05-31 14:50 ` Nick Dokos
  0 siblings, 2 replies; 7+ messages in thread
From: Uwe Brauer @ 2019-05-31 13:08 UTC (permalink / raw)
  To: emacs-orgmode



Hi 

I am running Ubuntu 16.06, matlab 2018b and  I am using the python
kernel to use matlab from within org mode


Thanks to John Kitchin, I have the following setting

* Lisp setting
#+BEGIN_SRC emacs-lisp
(setq org-confirm-babel-evaluate nil)   ;don't prompt me to confirm everytime I want to evaluate a block

;;; display/update images in the buffer after I evaluate
(add-hook 'org-babel-after-execute-hook 'org-display-inline-images 'append)
    

(add-to-list 'org-src-lang-modes '("matlab" . matlab))
(setq python-shell-interpreter "python3")

;; set default headers for convenience
(setq org-babel-default-header-args:matlab
      '((:results . "output replace")
	(:session . "matlab")
	(:kernel . "matlab")
	(:exports . "code")
	(:cache .   "no")
	(:noweb . "no")
	(:hlines . "no")
	(:tangle . "no")))

(defalias 'org-babel-execute:matlab 'org-babel-execute:ipython)
(defalias 'org-babel-prep-session:matlab 'org-babel-prep-session:ipython)
(defalias 'org-babel-matlab-initiate-session 'org-babel-ipython-initiate-session)
#+END_SRC


* The problem

When I run 

#+begin_src matlab :results output latex :exports results  :eval never-export 
disp('*Step 3:*')
disp('*Step 3:*  Calculate this')
#+end_src


On obtain 
#+RESULTS:
#+begin_export latex
,*Step 3:*
,*Step 3:*  Calculate this
#+end_export


Instead of 

#+begin_export latex
*Step 3:*
*Step 3:*  Calculate this
#+end_export


Does anybody have an idea what is wrong there?

Uwe Brauer 

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-05-31 16:50 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-31 13:08 strange output when executing matlab using babel, strange , Uwe Brauer
2019-05-31 13:57 ` John Kitchin
2019-05-31 14:30   ` Uwe Brauer
2019-05-31 14:50 ` Nick Dokos
2019-05-31 14:56   ` Uwe Brauer
2019-05-31 15:59     ` John Kitchin
2019-05-31 16:46       ` Uwe Brauer

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).