search
HomeDatabaseMysql Tutorial思路总结-----对微博情感分析的的挖掘

一朋友由于工作需要,准备对新浪微博进行相关的抓取挖掘。特别是情感分析这一块,便于他后期的实验实践。实际上,文本挖掘及分析在未来都会产生较大的效果。举一个简单的例子,现在地铁里的每个人每天都会去刷新自己的人人好友圈,微信好友消息。而这些消息

    一朋友由于工作需要,准备对新浪微博进行相关的抓取挖掘。特别是情感分析这一块,便于他后期的实验实践。实际上,文本挖掘及分析在未来都会产生较大的效果。举一个简单的例子,现在地铁里的每个人每天都会去刷新自己的人人好友圈,微信好友消息。而这些消息大部分是基于文本的。如何对这些原始的消息进行挖掘。进而为相应的精准营销做准备。在以后的营销中将会产生重大效果。

原始数据

    这一部分的内容,我们可以通过爬虫技术来抓取。通过聚类算法,找到相同话题的所有微博。然后拿来做为原始数据。还有就是用户好友圈内的评价消息,还有用户产生的连接消息,等等。这些都可以作为原始数据来归入我们的数据库。

确订目标(商业理解)

    这一步也同时与业务理解要很好的关联起来,首先,我们是要用这些原始数据来作什么?比如,我们用情感分析,所有不同用户对同一事件的理解。我们要将他们的微博信息里的关键词找出来。然而进行相应的查找算法,进而确定所有用户对这一事件的评价。然后,我们要通过用户的评价,找到有二次商业利用值的客户。然后确订为目标客户。

数据理解

   所抓取到的微博内容是什么,里边带几个链接?是用什么符号与之相连?文字,图片的分类,另外还有评论信息是否也有参考价值。里边的特殊符号代表什么?等等。这些信息,那些是对我们的来说是有用的,如何去用?比如说要从文本中挖掘出关建字,进行相关的营销活动。从而确定博主的情感动向。进而可以做些什么?理解我们的数据,才能更好的抓取到我们所要使用的数据。

模型建立

   有人说,搞数据挖掘的人就是要来做这一部分的内容。你要建立一个好的模型,那以后的数据通过你的这个模型,那么你所需要的内容自动地就会呈现出来。而这一部分也是整个数据挖掘里最难的部分。

   比如说我们的微博数据,我们可以通过决策树算法建立模型。最后输出那些关健字的客户就是我们的目标客户。又或者,我们可以通过神经网络的算法建立模型,找到相关的所的决策项。实际上,数据挖掘所用到的方法很多,也很复杂,我也是到现在还是没有弄清楚一些算法的核心思想。但这样并不影响我们来使用相关的算法来进行挖掘。再者说,现在的挖掘对象,真正上PB内容的资料也不是很多的。很多企业还停留在小型机的阶段。所以,有的时候,我会开玩笑的说:数据量太小的话,EXECL会更好一些,然后是ACCESS数据库。再然后就是ORCALE数据库.....

   模型建立是一个比较幸苦的工作,可是如果建立完成后,一般3-5年不会发生变化。比如我们现在的信用卡的信用评分系统。

模型评估

   这一部分内容,是进行相关优化。也就是说模型建立好了,开始要跑业务了。要测试一下看它到底能跑到什么样的程度。有的时候,你挖掘了半年,也找到的目标客户,结果被其他人先用其他方法吸引走了,怎么办?所以才要有模型评估这件工作。

   先将大数据里的一部分数据,一般是40%拿来先做训练,你也可以拿少量来试一试。然后看完成这些数据需要多长时间。换了其他的算法后,是否可以提高挖掘时间。一般这一步的数据分配要遵守一个4:3:3的原则,即40%拿来做训练,30%来做测试,另外的30%拿来做验证。综合来说,才能够评价这个模型的好坏,以及这个模型是否能产生它的相应价值。

发布模型

   这是最后一步,让所有微博数据进行相应的算法优化。进而达到最好的挖掘效果。


在以上的这几个步骤中,模型评估与商业理解其实也是相辅相成的,因为这两个主要是与数据最为密切。而数据理解与商业理解又是相互制约的,很多时候,我们是有了大数据,但是我们找不到我们的所要挖掘的目标在那里,这时就需要不断的修订我们的商业理解与数据理解,然而,模型的相关内容,在整个闭环的过程中并不显的那么重要。有的时候,客户的一个很简单的需求,我们并不一定要用复杂的技术来实现,简单也许就意味着胜利。


再来说说在文本挖掘中的思路,少量的文本信息。我们可以放在在WORD里用复制粘贴来完成,多的话可以用EXCEL,再多的话可以用U1,要是还是多就用SAS与R,再多就用其他的了,具体什么软件,我也没用过。


好了,就先总结这么多吧。下周有空再写吧!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Explain the InnoDB Buffer Pool and its importance for performance.Explain the InnoDB Buffer Pool and its importance for performance.Apr 19, 2025 am 12:24 AM

InnoDBBufferPool reduces disk I/O by caching data and indexing pages, improving database performance. Its working principle includes: 1. Data reading: Read data from BufferPool; 2. Data writing: After modifying the data, write to BufferPool and refresh it to disk regularly; 3. Cache management: Use the LRU algorithm to manage cache pages; 4. Reading mechanism: Load adjacent data pages in advance. By sizing the BufferPool and using multiple instances, database performance can be optimized.

MySQL vs. Other Programming Languages: A ComparisonMySQL vs. Other Programming Languages: A ComparisonApr 19, 2025 am 12:22 AM

Compared with other programming languages, MySQL is mainly used to store and manage data, while other languages ​​such as Python, Java, and C are used for logical processing and application development. MySQL is known for its high performance, scalability and cross-platform support, suitable for data management needs, while other languages ​​have advantages in their respective fields such as data analytics, enterprise applications, and system programming.

Learning MySQL: A Step-by-Step Guide for New UsersLearning MySQL: A Step-by-Step Guide for New UsersApr 19, 2025 am 12:19 AM

MySQL is worth learning because it is a powerful open source database management system suitable for data storage, management and analysis. 1) MySQL is a relational database that uses SQL to operate data and is suitable for structured data management. 2) The SQL language is the key to interacting with MySQL and supports CRUD operations. 3) The working principle of MySQL includes client/server architecture, storage engine and query optimizer. 4) Basic usage includes creating databases and tables, and advanced usage involves joining tables using JOIN. 5) Common errors include syntax errors and permission issues, and debugging skills include checking syntax and using EXPLAIN commands. 6) Performance optimization involves the use of indexes, optimization of SQL statements and regular maintenance of databases.

MySQL: Essential Skills for Beginners to MasterMySQL: Essential Skills for Beginners to MasterApr 18, 2025 am 12:24 AM

MySQL is suitable for beginners to learn database skills. 1. Install MySQL server and client tools. 2. Understand basic SQL queries, such as SELECT. 3. Master data operations: create tables, insert, update, and delete data. 4. Learn advanced skills: subquery and window functions. 5. Debugging and optimization: Check syntax, use indexes, avoid SELECT*, and use LIMIT.

MySQL: Structured Data and Relational DatabasesMySQL: Structured Data and Relational DatabasesApr 18, 2025 am 12:22 AM

MySQL efficiently manages structured data through table structure and SQL query, and implements inter-table relationships through foreign keys. 1. Define the data format and type when creating a table. 2. Use foreign keys to establish relationships between tables. 3. Improve performance through indexing and query optimization. 4. Regularly backup and monitor databases to ensure data security and performance optimization.

MySQL: Key Features and Capabilities ExplainedMySQL: Key Features and Capabilities ExplainedApr 18, 2025 am 12:17 AM

MySQL is an open source relational database management system that is widely used in Web development. Its key features include: 1. Supports multiple storage engines, such as InnoDB and MyISAM, suitable for different scenarios; 2. Provides master-slave replication functions to facilitate load balancing and data backup; 3. Improve query efficiency through query optimization and index use.

The Purpose of SQL: Interacting with MySQL DatabasesThe Purpose of SQL: Interacting with MySQL DatabasesApr 18, 2025 am 12:12 AM

SQL is used to interact with MySQL database to realize data addition, deletion, modification, inspection and database design. 1) SQL performs data operations through SELECT, INSERT, UPDATE, DELETE statements; 2) Use CREATE, ALTER, DROP statements for database design and management; 3) Complex queries and data analysis are implemented through SQL to improve business decision-making efficiency.

MySQL for Beginners: Getting Started with Database ManagementMySQL for Beginners: Getting Started with Database ManagementApr 18, 2025 am 12:10 AM

The basic operations of MySQL include creating databases, tables, and using SQL to perform CRUD operations on data. 1. Create a database: CREATEDATABASEmy_first_db; 2. Create a table: CREATETABLEbooks(idINTAUTO_INCREMENTPRIMARYKEY, titleVARCHAR(100)NOTNULL, authorVARCHAR(100)NOTNULL, published_yearINT); 3. Insert data: INSERTINTObooks(title, author, published_year)VA

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

MinGW - Minimalist GNU for Windows

MinGW - Minimalist GNU for Windows

This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

WebStorm Mac version

WebStorm Mac version

Useful JavaScript development tools

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

DVWA

DVWA

Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software

SecLists

SecLists

SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.