emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: John Kitchin <jkitchin@andrew.cmu.edu>
To: Adam Sneller <adam@earth2adam.com>
Cc: "emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>,
	Bruce D'Arcus <bdarcus@gmail.com>
Subject: Re: Citations with page numbers using helm-bibtex and org-ref
Date: Sun, 21 Feb 2021 12:40:38 -0500	[thread overview]
Message-ID: <CAJ51ETq_1nPXnSxgPu+yiHJn_Y67jHYy08JPx-1HQ4FKh1EFXQ@mail.gmail.com> (raw)
In-Reply-To: <E884D94D-20D9-4A4D-B9E8-1E2F4FFC2697@earth2adam.com>

[-- Attachment #1: Type: text/plain, Size: 4803 bytes --]

It seems like some ideas are getting mixed up in your description. A cite
link in org-ref is related to a bibtex entry in a bibtex file, not to an
org heading in an org-file. In other words in your example, I would expecta
bibtex entry with the key bradley1973es to exist in one of the default
bibliography files you use (or in the one you define in a bibliography
link). The notes are just for your purposes.

the headings/links in your notes file will not show up in any completion
backend in org-ref for citation selection, as only the bibtex entries are
used to construct those.

 If you are looking for a way to select one of those headings from your
notes, and then insert the appropriate link, you would have to use
something different than org-ref. there is not presently a way to map an
annotated cite link to the specific note. I am not even sure you can write
a function that does that, as the functions only take a key for looking up
the note file, and not the description too. It certainly is possible to
write a new function that would work on the link at point to do that, and
to call it interactively, or add it as an action though. You would still
get the key to open the note file, and then use the link description if it
exists to somehow search forward for the relevant heading or text, failing
gracefully if you, for example, make a cite to a page you did not make a
note on.

When it comes time to authoring a paper, I think the workflow is you would
have to open the notes you made, find the section you want to use in your
paper, and copy the link you put in your notes to your new document. There
are some variations you might consider, but none of them would really be
integrated into the org-ref completion mechanisms that are generated from
the bibtex entries.

For example you  might store the link or parts in a property like this:

* The Accelerator-Multiplier Model
  :PROPERTIES:
  :key:      bradley1973es
  :page:     p200
  :cite: [[cite:bradley1973es][p200]]
  :END:


and then write a small function you use interactively to copy it, e.g.

#+BEGIN_SRC emacs-lisp
(defun get-link ()
  (interactive)
  (kill-new (org-entry-get (point) "cite")))
#+END_SRC

and you might bind that to a key if you use it a lot. Alternatively you
might put the key in file-level property, and only store the page, and use
property inheritance, to build the link. There are a lot of options to
choose from. But, simply copying and pasting a link might also be the
simplest.

It might be possible to use the org-store/insert-link machinery for this
too, but I have found that to be trickier than I thought it should be in
the past.

John

-----------------------------------
Professor John Kitchin
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
@johnkitchin
http://kitchingroup.cheme.cmu.edu



On Sun, Feb 21, 2021 at 12:13 PM Adam Sneller <adam@earth2adam.com> wrote:

> Hi Bruce/John,
>
> Thanks for getting back to me. So I guess your notes file would look
> something like this?
>
>
> #+TITLE: Bradley, J. (1973): Essential Mathematics For Economists
>
> * Dynamic models: the consumption function
> [[cite:bradley1973es][p164]]
>
> * Changes in Capital Stock
> [[cite:bradley1973es][p188]]
>
> * The Accelerator-Multiplier Model
> [[cite:bradley1973es][p200]]
>
>
> So when when it comes time to author your paper, if you run org-store-link
> on any of these, the description gets stripped off the link, so that only
> cite:bradley1973es is stored (which obviously defeats the purpose). And if
> you copy the link over by hand, it maps back to the document
> bradley197es.org (not the actual note).
>
> Am I missing anything?
>
> Adam
>
> On 21 Feb 2021, at 12:21, Bruce D'Arcus <bdarcus@gmail.com> wrote:
>
> On Sat, Feb 20, 2021 at 10:31 PM Adam Sneller <adam.sneller@ms2.digital>
> wrote:
>
> I currently use org-ref and helm-bibtex to manage my database of academic
> sources, with one notes file per source. A lot of my sources are books. So
> note typically grow over time, as I add multiple headers (each pertaining
> to a chapter or topic/note taken from that source).
>
> But now I want to produce a citation that references the page numbers
> where I captured that note...
>
> What is the recommended way to handle this? Are you breaking notes into
> individual files, each with their own @inbook citation?
>
>
> Generally speaking, referencing page numbers and sections of a cited
> source is not handled by dedicated citations, but rather by
> annotations on the containing citation (book etc.).
>
> So in the pandoc syntax, for example, [@book, p23].
>
> I do the same with notes, and just included the specific citation with
> the note if I need to maintain the specific source page.
>
> Bruce
>
>
>

[-- Attachment #2: Type: text/html, Size: 6343 bytes --]

  reply	other threads:[~2021-02-21 17:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-21  0:26 Citations with page numbers using helm-bibtex and org-ref Adam Sneller
2021-02-21 12:21 ` Bruce D'Arcus
2021-02-21 13:30   ` John Kitchin
2021-02-21 17:13   ` Adam Sneller
2021-02-21 17:40     ` John Kitchin [this message]
2021-02-21 19:05       ` Adam Sneller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAJ51ETq_1nPXnSxgPu+yiHJn_Y67jHYy08JPx-1HQ4FKh1EFXQ@mail.gmail.com \
    --to=jkitchin@andrew.cmu.edu \
    --cc=adam@earth2adam.com \
    --cc=bdarcus@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).