From: "\"Wilfred Zegwaard (privé)\"" <wilfred.zegwaard@home.nl>
To: help-gnu-emacs@gnu.org
Subject: Fuzzy search (was: Counting words)
Date: Thu, 12 Apr 2007 23:06:30 +0200 [thread overview]
Message-ID: <461E9F56.6040803@home.nl> (raw)
In-Reply-To: <mailman.1904.1176205848.7795.help-gnu-emacs@gnu.org>
Both methodes replace-regexp en count-matches are exact. That is not
exactly what I want in the end. I'm looking for a type of fuzzy search
with words which nearly exact. (Like the R statistical fuzzy search).
Eg.: the hero was here
Fuzzy search in the document, and it finds: the hero was there
It almost matches.
This is what I'm looking for. Any functions in Emacs which does the trick?
Wilfred
Wilfred Zegwaard (privé) wrote:
> I found the wordcount thing.
> I mean specific instances of words. The number of times eg that "the"
> occurs in a text. But I need to search on specific combinations, like
> "the exact word", but also a fuzzy search on specific combinations.
>
> Not HTML tags, but specific strings that this package that I use calls
> TAGS and who are easily identifiable with a string or string combination.
>
> Wilfred
>
>
Wilfred,
you can use replace-regexp to do this
Try
M-x replace-regexp
\bthe exact phrase\b
\&
\b means word-boundary,
\& means replace with what was found.
This is a bit nasty, but after the regexp-replace has
finished, it should echo "Replaced xx occurrences"
to the minibuffer.
HTH,
Colin S. Miller
--
Replace the obvious in my email address with the first three letters of
the hostname to reply.
_______________________________________________
help-gnu-emacs mailing list
help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs
--
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.446 / Virus Database: 269.2.0/757 - Release Date: 11-4-2007
17:14
next prev parent reply other threads:[~2007-04-12 21:06 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.1903.1176202249.7795.help-gnu-emacs@gnu.org>
2007-04-10 11:05 ` Counting words Robert D. Crawford
2007-04-10 11:46 ` "Wilfred Zegwaard (privé)"
2007-04-10 15:13 ` Peter Dyballa
2007-04-10 17:37 ` "Wilfred Zegwaard (privé)"
[not found] ` <mailman.1904.1176205848.7795.help-gnu-emacs@gnu.org>
2007-04-11 19:42 ` Colin S. Miller
2007-04-12 13:14 ` thorne
2007-04-12 21:06 ` "Wilfred Zegwaard (privé)" [this message]
2007-04-12 21:43 ` Fuzzy search (was: Counting words) Peter Dyballa
2007-04-12 22:20 ` "Wilfred Zegwaard (privé)"
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=461E9F56.6040803@home.nl \
--to=wilfred.zegwaard@home.nl \
--cc=help-gnu-emacs@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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.