[CWB] Dramatic texts in cqpweb

Graham Ranger -- UAPV graham.ranger at univ-avignon.fr
Mon Nov 27 15:22:38 CET 2017


Hi Andrew,
Thanks for this: works perfectly!
(Another suggestion, from Simon Meier-Vieracker, on similar lines, with 
a global constraint, is: <sp>[]+</sp> :: match.sp_who = "SGANARELLE" 
This would perhaps be useful when the same character name turns up in 
different plays, to limit answers to one play, by combining multiple 
constraints...)
Best,
Graham.


Le 27/11/2017 à 13:54, Hardie, Andrew a écrit :
> Hi Graham,
>
> Try the following CQP syntax:
>
> <sp_who="somename"> []+ </sp_who>
>
> Note that you have to treat sp_who as an independent s-attribute from sp (because it is).
>
> best
>
> Andrew
>
> -----Original Message-----
> From: cwb-bounces at sslmit.unibo.it [mailto:cwb-bounces at sslmit.unibo.it] On Behalf Of Graham Ranger -- UAPV
> Sent: 27 November 2017 11:31
> To: cwb at sslmit.unibo.it
> Subject: Re: [CWB] Dramatic texts in cqpweb
>
> Dear all,
> A question on xml tags within cqpweb.
> It is possible to search for text inside simple xml tags, so <title>
> (+)+ </title> will give all the titles recorded inside xml tags in a corpus.
> However, is it possible to use attributes inside these searches, to
> isolate an act, a scene, a speaker, etc? I've tried with simple query
> syntax, i.e. <sp who="somename"> (+)+ </sp> but that gives no results. I
> imagine that it might be possible to set up a label as a wildcard and
> then use a global constraint, in cqp syntax, but my experiments with
> standard regex wildcards have given no results worth speaking of.
> Any help in either direction (simple queries or cqp queries) on
> extracting material between xml tags with attributes would be much
> appreciated.
> Best,
> Graham.
> _______________________________________________
> CWB mailing list
> CWB at sslmit.unibo.it
> http://liste.sslmit.unibo.it/mailman/listinfo/cwb
> _______________________________________________
> CWB mailing list
> CWB at sslmit.unibo.it
> http://liste.sslmit.unibo.it/mailman/listinfo/cwb



More information about the CWB mailing list