Return-Path: X-Original-To: apmail-lucene-java-user-archive@www.apache.org Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9C8E6102C0 for ; Thu, 12 Feb 2015 17:44:27 +0000 (UTC) Received: (qmail 50038 invoked by uid 500); 12 Feb 2015 17:44:13 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 49977 invoked by uid 500); 12 Feb 2015 17:44:13 -0000 Mailing-List: contact java-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-user@lucene.apache.org Delivered-To: mailing list java-user@lucene.apache.org Received: (qmail 49965 invoked by uid 99); 12 Feb 2015 17:44:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 12 Feb 2015 17:44:13 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=AC_DIV_BONANZA,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of maisnam.ns@gmail.com designates 209.85.192.50 as permitted sender) Received: from [209.85.192.50] (HELO mail-qg0-f50.google.com) (209.85.192.50) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 12 Feb 2015 17:43:45 +0000 Received: by mail-qg0-f50.google.com with SMTP id e89so9102103qgf.9 for ; Thu, 12 Feb 2015 09:42:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=1FRIxi+yb6wd2VOPyZe7o7RM+SMvjPOaLJKs6FBHiVU=; b=l1FcPsYcQMyawpOYz7t8CWIcA0plbEDK3zZ2ygSn1PFTC1S8G218EFlD62OPx4EGia 1p0GTj96RsgUkX1YEvYoPomipQK12IBNz31xYadnZwRpNp4ekA0CSjPidrmoqpUKEvU/ NCm1swRK0GOBlC7An8T47hsFLjpdBkqGHYEfVUeGPdRePJZAaySiDU+sr9UWvXEDhvgU bdatCYJeKT68nTDSyf2oJHVvj1XFaqYN/GbzHxeT1G38kIPSasJn72ZTwu/ZetQKZvfQ m+FsVl/fTQbGRFr9olOe/8BUvjbZOoHXL2+aWtNjN31zlO8XgEDu0dT4EJEc6OAPOES3 6cOA== MIME-Version: 1.0 X-Received: by 10.140.19.14 with SMTP id 14mr12529017qgg.37.1423762979035; Thu, 12 Feb 2015 09:42:59 -0800 (PST) Received: by 10.140.29.101 with HTTP; Thu, 12 Feb 2015 09:42:59 -0800 (PST) Date: Thu, 12 Feb 2015 23:12:59 +0530 Message-ID: Subject: occurrence of two terms with the highest frequency From: Maisnam Ns To: java-user@lucene.apache.org Content-Type: multipart/alternative; boundary=001a113527229c5ecc050ee7a6ea X-Virus-Checked: Checked by ClamAV on apache.org --001a113527229c5ecc050ee7a6ea Content-Type: text/plain; charset=UTF-8 Hi, Can someone help me with this use case. Use case: Say there are 4 key words 'Flying', 'Shooting', 'fighting' and 'looking' in100 documents to search for. Consider 'Flying' and 'Shooting' co- occurs (together) in 70 documents where as 'Flying and 'fighting' co- occurs in 14 documents 'Flying' and 'looking' co-occurs in 2 documents and so on. I have to list them in order or rather show them on a web page 1. Flying , Shooting -70 2. Flying , fighting - 14 3 Flying , looking -2 How to achieve this and please tell me what kind of query is this co-occurrence frequency. Is this possible in Lucene.And how to proceed . Please help and thanks in advance. Regards --001a113527229c5ecc050ee7a6ea--